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