package com.gyee;

import org.springframework.boot.ApplicationArguments;
import org.springframework.boot.ApplicationRunner;
import org.springframework.boot.Banner;
import org.springframework.boot.WebApplicationType;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.data.mongo.MongoDataAutoConfiguration;
import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration;
import org.springframework.boot.autoconfigure.mongo.MongoAutoConfiguration;
import org.springframework.boot.builder.SpringApplicationBuilder;


/**
 * 项目启动方法
 * @author gyee
 *
 */
@SpringBootApplication(exclude = {DataSourceAutoConfiguration.class, MongoAutoConfiguration.class, MongoDataAutoConfiguration.class})
public class SpringbootStart  implements ApplicationRunner {


    @Override
    public void run(ApplicationArguments args) throws Exception {

    }


    public static void main(String[] args) throws Exception {

//        SpringApplication.run(SpringbootStart.class, args);

        new SpringApplicationBuilder(SpringbootStart.class)
                .web(WebApplicationType.NONE) // .REACTIVE, .SERVLET
                .bannerMode(Banner.Mode.OFF)
                .run(args);
        System.out.println("******************项目启动完成*************************");


    }

}
