我想通过以下部署春季启动应用到JBoss 此.它运行良好但SpringBootServletInitializer在1.4.0.RELEASE中已弃用.我应该使用哪一个?
Maven依赖
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>1.4.0.RELEASE</version>
</parent>
Run Code Online (Sandbox Code Playgroud)
Java代码
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.context.web.SpringBootServletInitializer;
@SpringBootApplication
public class DemoApplication extends SpringBootServletInitializer {
public static void main(String[] args) {
SpringApplication.run(DemoApplication.class, args);
}
}
Run Code Online (Sandbox Code Playgroud)
Ama*_*har 157
您正在使用org.springframework.boot.context.web.SpringBootServletInitializer
此功能已弃用.代替:
org.springframework.boot.web.support.SpringBootServletInitializer
org.springframework.boot.web.servlet.support.SpringBootServletInitializer
归档时间: |
|
查看次数: |
41524 次 |
最近记录: |