Skip to content

Commit ce41f3c

Browse files
committed
Move servlet http encoding auto-configuration into spring-boot-servlet
1 parent 49e85ab commit ce41f3c

File tree

13 files changed

+9
-53
lines changed

13 files changed

+9
-53
lines changed

spring-boot-project/spring-boot-autoconfigure-all/build.gradle

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
plugins {
22
id "java-library"
3-
id "org.springframework.boot.auto-configuration"
4-
id "org.springframework.boot.configuration-properties"
53
id "org.springframework.boot.deployed"
64
id "org.springframework.boot.optional-dependencies"
75
}

spring-boot-project/spring-boot-autoconfigure-all/src/main/java/org/springframework/boot/autoconfigure/web/servlet/package-info.java

Lines changed: 0 additions & 20 deletions
This file was deleted.

spring-boot-project/spring-boot-autoconfigure-all/src/main/resources/META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports

Lines changed: 0 additions & 1 deletion
This file was deleted.

spring-boot-project/spring-boot-autoconfigure-all/src/test/java/org/springframework/boot/autoconfigure/web/servlet/FilterOrderingIntegrationTests.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
import org.springframework.boot.autoconfigure.context.PropertyPlaceholderAutoConfiguration;
2727
import org.springframework.boot.http.converter.autoconfigure.HttpMessageConvertersAutoConfiguration;
2828
import org.springframework.boot.security.autoconfigure.servlet.SecurityAutoConfiguration;
29+
import org.springframework.boot.servlet.autoconfigure.HttpEncodingAutoConfiguration;
2930
import org.springframework.boot.session.autoconfigure.SessionAutoConfiguration;
3031
import org.springframework.boot.test.util.TestPropertyValues;
3132
import org.springframework.boot.web.server.WebServerFactoryCustomizerBeanPostProcessor;

spring-boot-project/spring-boot-docs/build.gradle

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,6 @@ dependencies {
6565
autoConfiguration(project(path: ":spring-boot-project:spring-boot-amqp", configuration: "autoConfigurationMetadata"))
6666
autoConfiguration(project(path: ":spring-boot-project:spring-boot-artemis", configuration: "autoConfigurationMetadata"))
6767
autoConfiguration(project(path: ":spring-boot-project:spring-boot-autoconfigure", configuration: "autoConfigurationMetadata"))
68-
autoConfiguration(project(path: ":spring-boot-project:spring-boot-autoconfigure-all", configuration: "autoConfigurationMetadata"))
6968
autoConfiguration(project(path: ":spring-boot-project:spring-boot-batch", configuration: "autoConfigurationMetadata"))
7069
autoConfiguration(project(path: ":spring-boot-project:spring-boot-cache", configuration: "autoConfigurationMetadata"))
7170
autoConfiguration(project(path: ":spring-boot-project:spring-boot-cassandra", configuration: "autoConfigurationMetadata"))
@@ -153,7 +152,6 @@ dependencies {
153152
configurationProperties(project(path: ":spring-boot-project:spring-boot-amqp", configuration: "configurationPropertiesMetadata"))
154153
configurationProperties(project(path: ":spring-boot-project:spring-boot-artemis", configuration: "configurationPropertiesMetadata"))
155154
configurationProperties(project(path: ":spring-boot-project:spring-boot-autoconfigure", configuration: "configurationPropertiesMetadata"))
156-
configurationProperties(project(path: ":spring-boot-project:spring-boot-autoconfigure-all", configuration: "configurationPropertiesMetadata"))
157155
configurationProperties(project(path: ":spring-boot-project:spring-boot-batch", configuration: "configurationPropertiesMetadata"))
158156
configurationProperties(project(path: ":spring-boot-project:spring-boot-cache", configuration: "configurationPropertiesMetadata"))
159157
configurationProperties(project(path: ":spring-boot-project:spring-boot-cassandra", configuration: "configurationPropertiesMetadata"))

spring-boot-project/spring-boot-docs/src/docs/antora/modules/appendix/pages/auto-configuration-classes/core.adoc

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,3 @@
44
The following auto-configuration classes are from the `spring-boot-autoconfigure` module:
55

66
include::partial$/auto-configuration-classes/spring-boot-autoconfigure.adoc[]
7-
8-
The following auto-configuration classes are from the `spring-boot-autoconfigure-all` module:
9-
10-
include::partial$/auto-configuration-classes/spring-boot-autoconfigure-all.adoc[]
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
* limitations under the License.
1515
*/
1616

17-
package org.springframework.boot.autoconfigure.web.servlet;
17+
package org.springframework.boot.servlet.autoconfigure;
1818

1919
import org.springframework.boot.autoconfigure.AutoConfiguration;
2020
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
* limitations under the License.
1515
*/
1616

17-
package org.springframework.boot.autoconfigure.web.servlet;
17+
package org.springframework.boot.servlet.autoconfigure;
1818

1919
import java.nio.charset.Charset;
2020
import java.nio.charset.StandardCharsets;
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
org.springframework.boot.servlet.actuate.autoconfigure.ServletManagementContextAutoConfiguration
22
org.springframework.boot.servlet.actuate.autoconfigure.exchanges.ServletHttpExchangesAutoConfiguration
33
org.springframework.boot.servlet.actuate.autoconfigure.mappings.ServletMappingsAutoConfiguration
4-
org.springframework.boot.servlet.autoconfigure.MultipartAutoConfiguration
4+
org.springframework.boot.servlet.autoconfigure.HttpEncodingAutoConfiguration
5+
org.springframework.boot.servlet.autoconfigure.MultipartAutoConfiguration
Lines changed: 2 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
* limitations under the License.
1515
*/
1616

17-
package org.springframework.boot.autoconfigure.web.servlet;
17+
package org.springframework.boot.servlet.autoconfigure;
1818

1919
import java.util.ArrayList;
2020
import java.util.List;
@@ -26,8 +26,6 @@
2626
import org.springframework.beans.factory.NoSuchBeanDefinitionException;
2727
import org.springframework.boot.test.util.TestPropertyValues;
2828
import org.springframework.boot.web.context.servlet.AnnotationConfigServletWebApplicationContext;
29-
import org.springframework.boot.web.server.WebServerFactoryCustomizerBeanPostProcessor;
30-
import org.springframework.boot.web.server.servlet.MockServletWebServerFactory;
3129
import org.springframework.boot.web.servlet.filter.OrderedFormContentFilter;
3230
import org.springframework.boot.web.servlet.filter.OrderedHiddenHttpMethodFilter;
3331
import org.springframework.context.annotation.Bean;
@@ -140,7 +138,7 @@ private AnnotationConfigServletWebApplicationContext doLoad(Class<?>[] configs,
140138
AnnotationConfigServletWebApplicationContext applicationContext = new AnnotationConfigServletWebApplicationContext();
141139
TestPropertyValues.of(environment).applyTo(applicationContext);
142140
applicationContext.register(configs);
143-
applicationContext.register(MinimalWebAutoConfiguration.class, HttpEncodingAutoConfiguration.class);
141+
applicationContext.register(HttpEncodingAutoConfiguration.class);
144142
applicationContext.setServletContext(new MockServletContext());
145143
applicationContext.refresh();
146144
return applicationContext;
@@ -179,19 +177,4 @@ OrderedFormContentFilter formContentFilter() {
179177

180178
}
181179

182-
@Configuration(proxyBeanMethods = false)
183-
static class MinimalWebAutoConfiguration {
184-
185-
@Bean
186-
MockServletWebServerFactory mockServletWebServerFactory() {
187-
return new MockServletWebServerFactory();
188-
}
189-
190-
@Bean
191-
static WebServerFactoryCustomizerBeanPostProcessor servletWebServerCustomizerBeanPostProcessor() {
192-
return new WebServerFactoryCustomizerBeanPostProcessor();
193-
}
194-
195-
}
196-
197180
}

spring-boot-project/spring-boot-test-autoconfigure/src/main/resources/META-INF/spring/org.springframework.boot.test.autoconfigure.web.servlet.AutoConfigureWebMvc.imports

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,6 @@ optional:org.springframework.boot.thymeleaf.autoconfigure.ThymeleafAutoConfigura
99
optional:org.springframework.boot.validation.autoconfigure.ValidationAutoConfiguration
1010
org.springframework.boot.autoconfigure.context.MessageSourceAutoConfiguration
1111
org.springframework.boot.autoconfigure.task.TaskExecutionAutoConfiguration
12-
org.springframework.boot.autoconfigure.web.servlet.HttpEncodingAutoConfiguration
12+
org.springframework.boot.servlet.autoconfigure.HttpEncodingAutoConfiguration
1313
org.springframework.boot.webmvc.autoconfigure.WebMvcAutoConfiguration
1414
org.springframework.boot.webmvc.autoconfigure.error.ErrorMvcAutoConfiguration

spring-boot-project/spring-boot-test-autoconfigure/src/test/java/org/springframework/boot/test/autoconfigure/web/servlet/WebMvcTestAutoConfigurationIntegrationTests.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,12 @@
2020

2121
import org.springframework.beans.factory.annotation.Autowired;
2222
import org.springframework.boot.autoconfigure.task.TaskExecutionAutoConfiguration;
23-
import org.springframework.boot.autoconfigure.web.servlet.HttpEncodingAutoConfiguration;
2423
import org.springframework.boot.freemarker.autoconfigure.FreeMarkerAutoConfiguration;
2524
import org.springframework.boot.groovy.template.autoconfigure.GroovyTemplateAutoConfiguration;
2625
import org.springframework.boot.mustache.autoconfigure.MustacheAutoConfiguration;
2726
import org.springframework.boot.security.oauth2.client.autoconfigure.OAuth2ClientAutoConfiguration;
2827
import org.springframework.boot.security.oauth2.server.resource.autoconfigure.servlet.OAuth2ResourceServerAutoConfiguration;
28+
import org.springframework.boot.servlet.autoconfigure.HttpEncodingAutoConfiguration;
2929
import org.springframework.boot.thymeleaf.autoconfigure.ThymeleafAutoConfiguration;
3030
import org.springframework.context.ApplicationContext;
3131
import org.springframework.core.task.AsyncTaskExecutor;

0 commit comments

Comments
 (0)