package com.shanghaichengdi.ghjgitem;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;
import org.springframework.cache.annotation.EnableCaching;
import org.springframework.scheduling.annotation.EnableAsync;
import org.springframework.scheduling.annotation.EnableScheduling;
import org.springframework.transaction.annotation.EnableTransactionManagement;

@SpringBootApplication
//开启定时任务
@EnableScheduling
//开启异步方法调用
@EnableAsync
@EnableCaching
//开启事务支持
@EnableTransactionManagement
public class GhjgItemServerApplication extends SpringBootServletInitializer {

  public static void main(String[] args) {
    SpringApplication.run(GhjgItemServerApplication.class, args);
  }

  @Override
  protected SpringApplicationBuilder configure(SpringApplicationBuilder builder) {
    return builder.sources(GhjgItemServerApplication.class);
  }

}
