guang
2023-05-06 7201205af85508421037119ba66b3a6a48de61ec
提交 | 用户 | age
9e1c8d 1 package com.hx.other.service;
G 2
3 import com.hx.other.service.config.UniqueNameGenerator;
4 import com.thebeastshop.forest.springboot.annotation.ForestScan;
720120 5 import org.mybatis.spring.boot.autoconfigure.MybatisAutoConfiguration;
9e1c8d 6 import org.springframework.boot.CommandLineRunner;
G 7 import org.springframework.boot.SpringApplication;
8 import org.springframework.boot.builder.SpringApplicationBuilder;
9 import org.springframework.boot.web.servlet.ServletComponentScan;
10 import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;
11 import org.springframework.boot.autoconfigure.SpringBootApplication;
12 import org.springframework.context.annotation.ComponentScan;
13 import org.mybatis.spring.annotation.MapperScan;
14 import com.hx.util.AesUtil;
15
16 @SpringBootApplication
17 @MapperScan({"com.gitee.sunchenbin.mybatis.actable.dao.*","com.hx.other.service.dao.*"})
18 @ComponentScan(basePackages = {"com.gitee.sunchenbin.mybatis.actable.manager.*","com.hx.other.service.*","com.hx.common.*"},nameGenerator = UniqueNameGenerator.class)
19 @ServletComponentScan
20 @ForestScan(basePackages = "com.hx.other.service.api.*")
21 public class PhiOtherService extends SpringBootServletInitializer implements CommandLineRunner {
22
23     public static void main(String[] args) {
24         SpringApplication.run(PhiOtherService.class, args);
25     }
26
27     @Override
28     protected SpringApplicationBuilder configure(SpringApplicationBuilder builder) {
29         return builder.sources(PhiOtherService.class);
30     }
31
32     @Override
33     public void run(String... args) throws Exception {
34         System.out.println("SpringBoot is Running...");
35     }
36 }