package info.aspirecn.iov.sjjh.supplier10000027;

import info.aspirecn.rdc.aspirecloud.node.except.annotations.EnableAspireCloudRdcHandleExcept;
import lombok.extern.slf4j.Slf4j;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.netflix.eureka.EnableEurekaClient;
import org.springframework.context.ApplicationContext;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.core.env.Environment;
import org.springframework.util.StopWatch;

import cn.com.jit.new_vstk.exception.NewCSSException;

@SpringBootApplication
@EnableAspireCloudRdcHandleExcept
@Slf4j
@EnableEurekaClient
@ComponentScan("info.aspirecn.rdc.aspirecloud.node.except")
@ComponentScan("info.aspirecn.rdc.aspirecloud.node.brave")
@ComponentScan("info.aspirecn.iov.sjjh.supplier10000027")
public class App {

    public static void main(String[] args) {
        StopWatch watch = new StopWatch();
        watch.start();
        ApplicationContext context = SpringApplication.run(App.class, args);
        Environment environment = context.getBean(Environment.class);
        String applicationName = environment.getProperty("spring.application.name");

        watch.stop();
        log.info("{} 启动完毕，times={}s", applicationName, watch.getTotalTimeSeconds());
    }

}
