李旭东
2023-11-03 a07b4b6ff1c98dcf81338bb45d59308db7c058a9
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
package com.thhy;
 
import com.thhy.materials.modules.biz.helmet.smoke.SmokeServer;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.CommandLineRunner;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.openfeign.EnableFeignClients;
import org.springframework.scheduling.annotation.EnableScheduling;
 
import javax.annotation.Resource;
 
@SpringBootApplication
@MapperScan(basePackages = {"com.thhy.materials.modules.*.*.mapper"})
@EnableFeignClients
@EnableScheduling
public class MaterialsApplication implements CommandLineRunner {
 
    @Value("${materialstcpport}")
    private Integer tcpport;
 
    @Resource
    private SmokeServer smokeServer;
 
    public static void main(String[] args) {
        SpringApplication.run(MaterialsApplication.class,args);
    }
 
    @Override
    public void run(String... args) throws Exception {
        smokeServer.run(tcpport);
    }
 
}