Added proxyBeanMethods = false to configuration classes. Fixes #623
This commit is contained in:
@@ -166,7 +166,7 @@ public class LifecycleMvcAutoConfigurationTests {
|
||||
}
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableAutoConfiguration
|
||||
static class Config {
|
||||
|
||||
|
||||
@@ -55,7 +55,7 @@ public class RefreshAutoConfigurationClassPathTests {
|
||||
}
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableAutoConfiguration
|
||||
static class Config {
|
||||
|
||||
|
||||
@@ -59,7 +59,7 @@ public class RefreshAutoConfigurationMoreClassPathTests {
|
||||
}
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableAutoConfiguration
|
||||
static class Config {
|
||||
|
||||
|
||||
@@ -85,7 +85,7 @@ public class RefreshAutoConfigurationTests {
|
||||
}
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableAutoConfiguration(exclude = DataSourceAutoConfiguration.class)
|
||||
@EnableConfigurationProperties(ConfigProps.class)
|
||||
static class Config {
|
||||
|
||||
@@ -43,7 +43,7 @@ public class BootstrapDisabledAutoConfigurationIntegrationTests {
|
||||
}
|
||||
|
||||
@EnableAutoConfiguration
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
protected static class Application {
|
||||
|
||||
}
|
||||
|
||||
@@ -59,7 +59,7 @@ public class BootstrapOrderingAutoConfigurationIntegrationTests {
|
||||
}
|
||||
|
||||
@EnableAutoConfiguration
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
protected static class Application {
|
||||
|
||||
}
|
||||
|
||||
@@ -63,12 +63,12 @@ public class BootstrapOrderingCustomPropertySourceIntegrationTests {
|
||||
}
|
||||
|
||||
@EnableAutoConfiguration
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
protected static class Application {
|
||||
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
// This is added to bootstrap context as a source in bootstrap.properties
|
||||
protected static class PropertySourceConfiguration implements PropertySourceLocator {
|
||||
|
||||
|
||||
@@ -55,7 +55,7 @@ public class BootstrapOrderingSpringApplicationJsonIntegrationTests {
|
||||
}
|
||||
|
||||
@EnableAutoConfiguration
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
protected static class Application {
|
||||
|
||||
}
|
||||
|
||||
@@ -40,7 +40,7 @@ public class BootstrapSourcesOrderingTests {
|
||||
}
|
||||
|
||||
@EnableAutoConfiguration
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
protected static class Application {
|
||||
|
||||
}
|
||||
|
||||
@@ -49,7 +49,7 @@ public class MessageSourceConfigurationTests {
|
||||
.isEqualTo("Hello World!");
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableAutoConfiguration
|
||||
protected static class TestApplication {
|
||||
|
||||
|
||||
@@ -36,7 +36,7 @@ import static org.springframework.cloud.bootstrap.TestHigherPriorityBootstrapCon
|
||||
* @author Spencer Gibb
|
||||
*/
|
||||
@Order(0)
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableConfigurationProperties
|
||||
public class TestBootstrapConfiguration {
|
||||
|
||||
|
||||
@@ -379,13 +379,13 @@ public class BootstrapConfigurationTests {
|
||||
.isEqualTo("Hello added!");
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableConfigurationProperties
|
||||
protected static class BareConfiguration {
|
||||
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@ConfigurationProperties("expected")
|
||||
// This is added to bootstrap context as a source in bootstrap.properties
|
||||
protected static class PropertySourceConfiguration implements PropertySourceLocator {
|
||||
|
||||
@@ -85,12 +85,12 @@ public class BootstrapListenerHierarchyIntegrationTests {
|
||||
then(bootstrapContext.getParent()).isNull();
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
static class BasicConfiguration {
|
||||
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
static class RootConfiguration {
|
||||
|
||||
@Bean
|
||||
|
||||
@@ -49,7 +49,7 @@ public class EncryptionIntegrationTests {
|
||||
then(context.getBean(PasswordProperties.class).getPassword()).isEqualTo("test");
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableConfigurationProperties(PasswordProperties.class)
|
||||
protected static class TestConfiguration {
|
||||
|
||||
|
||||
@@ -125,7 +125,7 @@ public class EnvironmentManagerIntegrationTests {
|
||||
.isInstanceOf(WritableEnvironmentEndpointWebExtension.class);
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableAutoConfiguration
|
||||
protected static class TestConfiguration {
|
||||
|
||||
|
||||
@@ -115,7 +115,7 @@ public class ConfigurationPropertiesRebinderIntegrationTests {
|
||||
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableConfigurationProperties
|
||||
@ImportAutoConfiguration({ RefreshConfiguration.RebinderConfiguration.class,
|
||||
PropertyPlaceholderAutoConfiguration.class })
|
||||
@@ -139,7 +139,7 @@ public class ConfigurationPropertiesRebinderIntegrationTests {
|
||||
// Hack out a protected inner class for testing
|
||||
protected static class RefreshConfiguration extends RefreshAutoConfiguration {
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
protected static class RebinderConfiguration
|
||||
extends ConfigurationPropertiesRebinderAutoConfiguration {
|
||||
|
||||
|
||||
@@ -65,7 +65,7 @@ public class ConfigurationPropertiesRebinderLifecycleIntegrationTests {
|
||||
then(this.properties.getCount()).isEqualTo(1);
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableConfigurationProperties
|
||||
@Import({ RefreshConfiguration.RebinderConfiguration.class,
|
||||
PropertyPlaceholderAutoConfiguration.class })
|
||||
@@ -81,7 +81,7 @@ public class ConfigurationPropertiesRebinderLifecycleIntegrationTests {
|
||||
// Hack out a protected inner class for testing
|
||||
protected static class RefreshConfiguration extends RefreshAutoConfiguration {
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
protected static class RebinderConfiguration
|
||||
extends ConfigurationPropertiesRebinderAutoConfiguration {
|
||||
|
||||
|
||||
@@ -100,7 +100,7 @@ public class ConfigurationPropertiesRebinderListIntegrationTests {
|
||||
then(this.properties.getMessages().toString()).isEqualTo("[foo]");
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableConfigurationProperties
|
||||
@Import({ RefreshConfiguration.RebinderConfiguration.class,
|
||||
PropertyPlaceholderAutoConfiguration.class })
|
||||
@@ -116,7 +116,7 @@ public class ConfigurationPropertiesRebinderListIntegrationTests {
|
||||
// Hack out a protected inner class for testing
|
||||
protected static class RefreshConfiguration extends RefreshAutoConfiguration {
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
protected static class RebinderConfiguration
|
||||
extends ConfigurationPropertiesRebinderAutoConfiguration {
|
||||
|
||||
|
||||
@@ -68,7 +68,7 @@ public class ConfigurationPropertiesRebinderProxyIntegrationTests {
|
||||
then(this.properties.getExpiry().get("one")).isEqualTo(new Integer(56));
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableConfigurationProperties
|
||||
@Import({ Interceptor.class, RefreshConfiguration.RebinderConfiguration.class,
|
||||
PropertyPlaceholderAutoConfiguration.class, AopAutoConfiguration.class })
|
||||
@@ -94,7 +94,7 @@ public class ConfigurationPropertiesRebinderProxyIntegrationTests {
|
||||
// Hack out a protected inner class for testing
|
||||
protected static class RefreshConfiguration extends RefreshAutoConfiguration {
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
protected static class RebinderConfiguration
|
||||
extends ConfigurationPropertiesRebinderAutoConfiguration {
|
||||
|
||||
|
||||
@@ -86,7 +86,7 @@ public class ConfigurationPropertiesRebinderRefreshScopeIntegrationTests {
|
||||
then(this.properties.getCount()).isEqualTo(1);
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableConfigurationProperties
|
||||
@Import({ RefreshAutoConfiguration.class,
|
||||
ConfigurationPropertiesRebinderAutoConfiguration.class,
|
||||
|
||||
@@ -81,7 +81,7 @@ public class ContextRefresherIntegrationTests {
|
||||
then(this.properties.getMessage()).isEqualTo("Hello scope!");
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableConfigurationProperties(TestProperties.class)
|
||||
@EnableAutoConfiguration
|
||||
protected static class TestConfiguration {
|
||||
|
||||
@@ -160,12 +160,12 @@ public class ContextRefresherTests {
|
||||
return list;
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
protected static class Empty {
|
||||
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
// This is added to bootstrap context as a source in bootstrap.properties
|
||||
protected static class PropertySourceConfiguration implements PropertySourceLocator {
|
||||
|
||||
|
||||
@@ -72,7 +72,7 @@ public class RestartIntegrationTests {
|
||||
then(json).containsOnlyOnce("parent\": null");
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableAutoConfiguration
|
||||
protected static class TestConfiguration {
|
||||
|
||||
|
||||
@@ -52,7 +52,7 @@ public class ImportRefreshScopeIntegrationTests {
|
||||
then(this.service.getMessage()).isEqualTo("Hello scope!");
|
||||
}
|
||||
|
||||
@Configuration("service")
|
||||
@Configuration(value = "service", proxyBeanMethods = false)
|
||||
@RefreshScope
|
||||
public static class ExampleService {
|
||||
|
||||
@@ -62,7 +62,7 @@ public class ImportRefreshScopeIntegrationTests {
|
||||
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@Import({ RefreshAutoConfiguration.class, ExampleService.class })
|
||||
protected static class TestConfiguration {
|
||||
|
||||
|
||||
@@ -87,7 +87,7 @@ public class RefreshEndpointIntegrationTests {
|
||||
return entity;
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableAutoConfiguration
|
||||
protected static class ClientApp {
|
||||
|
||||
|
||||
@@ -150,7 +150,7 @@ public class RefreshScopeConcurrencyTests {
|
||||
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableConfigurationProperties(TestProperties.class)
|
||||
@Import({ RefreshAutoConfiguration.class,
|
||||
PropertyPlaceholderAutoConfiguration.class })
|
||||
|
||||
@@ -169,7 +169,7 @@ public class RefreshScopeConfigurationScaleTests {
|
||||
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableConfigurationProperties
|
||||
@Import({ RefreshAutoConfiguration.class,
|
||||
PropertyPlaceholderAutoConfiguration.class })
|
||||
|
||||
@@ -133,7 +133,7 @@ public class RefreshScopeConfigurationTests {
|
||||
|
||||
}
|
||||
|
||||
@Configuration("application")
|
||||
@Configuration(value = "application", proxyBeanMethods = false)
|
||||
@RefreshScope
|
||||
protected static class Application {
|
||||
|
||||
@@ -151,7 +151,7 @@ public class RefreshScopeConfigurationTests {
|
||||
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
protected static class ClientApp {
|
||||
|
||||
public static void main(String[] args) {
|
||||
|
||||
@@ -216,7 +216,7 @@ public class RefreshScopeIntegrationTests {
|
||||
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableConfigurationProperties(TestProperties.class)
|
||||
@EnableAutoConfiguration
|
||||
protected static class TestConfiguration {
|
||||
|
||||
@@ -199,7 +199,7 @@ public class RefreshScopeLazyIntegrationTests {
|
||||
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableConfigurationProperties(TestProperties.class)
|
||||
@ImportAutoConfiguration({ RefreshAutoConfiguration.class,
|
||||
PropertyPlaceholderAutoConfiguration.class })
|
||||
|
||||
@@ -91,7 +91,7 @@ public class RefreshScopeListBindingIntegrationTests {
|
||||
throw new IllegalStateException("Could not find test property source");
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableConfigurationProperties
|
||||
@Import({ RefreshAutoConfiguration.class,
|
||||
PropertyPlaceholderAutoConfiguration.class })
|
||||
|
||||
@@ -66,7 +66,7 @@ public class RefreshScopeNullBeanIntegrationTests {
|
||||
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
protected static class OptionalConfiguration {
|
||||
|
||||
@Bean
|
||||
@@ -77,7 +77,7 @@ public class RefreshScopeNullBeanIntegrationTests {
|
||||
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@Import({ RefreshAutoConfiguration.class, PropertyPlaceholderAutoConfiguration.class,
|
||||
OptionalConfiguration.class })
|
||||
protected static class TestConfiguration {
|
||||
|
||||
@@ -158,7 +158,7 @@ public class RefreshScopePureScaleTests {
|
||||
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@Import({ RefreshAutoConfiguration.class,
|
||||
PropertyPlaceholderAutoConfiguration.class })
|
||||
protected static class TestConfiguration {
|
||||
|
||||
@@ -153,7 +153,7 @@ public class RefreshScopeScaleTests {
|
||||
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableConfigurationProperties(TestProperties.class)
|
||||
@Import({ RefreshAutoConfiguration.class,
|
||||
PropertyPlaceholderAutoConfiguration.class })
|
||||
|
||||
@@ -56,7 +56,7 @@ public class RefreshScopeSerializationTests {
|
||||
return factory;
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
protected static class TestConfiguration {
|
||||
|
||||
@Bean
|
||||
|
||||
@@ -71,7 +71,7 @@ public class RefreshScopeWebIntegrationTests {
|
||||
then(message).isEqualTo("Hello Dave!");
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
@EnableAutoConfiguration
|
||||
protected static class Application {
|
||||
|
||||
|
||||
@@ -169,7 +169,7 @@ public class RefreshEndpointTests {
|
||||
return map.size();
|
||||
}
|
||||
|
||||
@Configuration
|
||||
@Configuration(proxyBeanMethods = false)
|
||||
protected static class Empty implements SmartApplicationListener {
|
||||
|
||||
private List<ApplicationEvent> events = new ArrayList<ApplicationEvent>();
|
||||
|
||||
Reference in New Issue
Block a user