Add new WebApplicationType enum to pave the way for Web Flux support

Closes gh-8077
This commit is contained in:
Andy Wilkinson
2017-01-24 15:58:14 +00:00
parent 4e3d606fad
commit 95f659f4f9
24 changed files with 259 additions and 152 deletions

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2016 the original author or authors.
* Copyright 2012-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -22,6 +22,7 @@ import javax.ws.rs.Produces;
import com.sun.jersey.spi.container.servlet.ServletContainer;
import org.springframework.boot.WebApplicationType;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainerFactory;
@@ -54,7 +55,8 @@ public class SampleJersey1Application {
}
public static void main(String[] args) {
new SpringApplicationBuilder(SampleJersey1Application.class).web(true).run(args);
new SpringApplicationBuilder(SampleJersey1Application.class)
.web(WebApplicationType.SERVLET).run(args);
}
}