Reduce need for bean method proxying and disable where not needed

Closes gh-9068
This commit is contained in:
Andy Wilkinson
2019-02-08 14:51:38 +00:00
parent 0f71f22f3c
commit 68bfb020aa
887 changed files with 2574 additions and 2542 deletions

View File

@@ -39,7 +39,7 @@ import org.springframework.jmx.export.MBeanExporter;
* @since 1.3.0
* @see SpringApplicationAdminMXBean
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@AutoConfigureAfter(JmxAutoConfiguration.class)
@ConditionalOnProperty(prefix = "spring.application.admin", value = "enabled", havingValue = "true", matchIfMissing = false)
public class SpringApplicationAdminJmxAutoConfiguration {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -39,7 +39,7 @@ import org.springframework.context.annotation.Configuration;
* @author Josh Thornhill
* @since 1.2.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(EnableRabbit.class)
class RabbitAnnotationDrivenConfiguration {
@@ -107,7 +107,7 @@ class RabbitAnnotationDrivenConfiguration {
return factory;
}
@Configuration
@Configuration(proxyBeanMethods = false)
@EnableRabbit
@ConditionalOnMissingBean(name = RabbitListenerConfigUtils.RABBIT_LISTENER_ANNOTATION_PROCESSOR_BEAN_NAME)
protected static class EnableRabbitConfiguration {

View File

@@ -81,13 +81,13 @@ import org.springframework.context.annotation.Import;
* @author Phillip Webb
* @author Artsiom Yudovin
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ RabbitTemplate.class, Channel.class })
@EnableConfigurationProperties(RabbitProperties.class)
@Import(RabbitAnnotationDrivenConfiguration.class)
public class RabbitAutoConfiguration {
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnMissingBean(ConnectionFactory.class)
protected static class RabbitConnectionFactoryCreator {
@@ -153,7 +153,7 @@ public class RabbitAutoConfiguration {
}
@Configuration
@Configuration(proxyBeanMethods = false)
@Import(RabbitConnectionFactoryCreator.class)
protected static class RabbitTemplateConfiguration {
@@ -202,7 +202,7 @@ public class RabbitAutoConfiguration {
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(RabbitMessagingTemplate.class)
@ConditionalOnMissingBean(RabbitMessagingTemplate.class)
@Import(RabbitTemplateConfiguration.class)

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -39,20 +39,20 @@ import org.springframework.context.annotation.EnableAspectJAutoProxy;
* @author Josh Long
* @see EnableAspectJAutoProxy
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ EnableAspectJAutoProxy.class, Aspect.class, Advice.class,
AnnotatedElement.class })
@ConditionalOnProperty(prefix = "spring.aop", name = "auto", havingValue = "true", matchIfMissing = true)
public class AopAutoConfiguration {
@Configuration
@Configuration(proxyBeanMethods = false)
@EnableAspectJAutoProxy(proxyTargetClass = false)
@ConditionalOnProperty(prefix = "spring.aop", name = "proxy-target-class", havingValue = "false", matchIfMissing = false)
public static class JdkDynamicAutoProxyConfiguration {
}
@Configuration
@Configuration(proxyBeanMethods = false)
@EnableAspectJAutoProxy(proxyTargetClass = true)
@ConditionalOnProperty(prefix = "spring.aop", name = "proxy-target-class", havingValue = "true", matchIfMissing = true)
public static class CglibAutoProxyConfiguration {

View File

@@ -58,7 +58,7 @@ import org.springframework.util.StringUtils;
* @author Kazuki Shimizu
* @author Mahmoud Ben Hassine
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ JobLauncher.class, DataSource.class, JdbcOperations.class })
@AutoConfigureAfter(HibernateJpaAutoConfiguration.class)
@ConditionalOnBean(JobLauncher.class)

View File

@@ -36,10 +36,10 @@ import org.springframework.transaction.PlatformTransactionManager;
*/
@ConditionalOnClass(PlatformTransactionManager.class)
@ConditionalOnMissingBean(BatchConfigurer.class)
@Configuration
@Configuration(proxyBeanMethods = false)
class BatchConfigurerConfiguration {
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnMissingBean(name = "entityManagerFactory")
static class JdbcBatchConfiguration {
@@ -53,7 +53,7 @@ class BatchConfigurerConfiguration {
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(EntityManagerFactory.class)
@ConditionalOnBean(name = "entityManagerFactory")
static class JpaBatchConfiguration {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -54,7 +54,7 @@ import org.springframework.util.Assert;
* @since 1.3.0
* @see EnableCaching
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(CacheManager.class)
@ConditionalOnBean(CacheAspectSupport.class)
@ConditionalOnMissingBean(value = CacheManager.class, name = "cacheResolver")
@@ -78,7 +78,7 @@ public class CacheAutoConfiguration {
return new CacheManagerValidator(cacheProperties, cacheManager);
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(LocalContainerEntityManagerFactoryBean.class)
@ConditionalOnBean(AbstractEntityManagerFactoryBean.class)
protected static class CacheManagerJpaDependencyConfiguration

View File

@@ -39,7 +39,7 @@ import org.springframework.util.StringUtils;
* @author Eddú Meléndez
* @since 1.4.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ Caffeine.class, CaffeineCacheManager.class })
@ConditionalOnMissingBean(CacheManager.class)
@Conditional({ CacheCondition.class })

View File

@@ -40,7 +40,7 @@ import org.springframework.util.StringUtils;
* @author Stephane Nicoll
* @since 1.4.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ Bucket.class, CouchbaseCacheManager.class })
@ConditionalOnMissingBean(CacheManager.class)
@ConditionalOnSingleCandidate(Bucket.class)

View File

@@ -38,7 +38,7 @@ import org.springframework.core.io.Resource;
* @author Madhura Bhave
* @since 1.3.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ Cache.class, EhCacheCacheManager.class })
@ConditionalOnMissingBean(org.springframework.cache.CacheManager.class)
@Conditional({ CacheCondition.class,

View File

@@ -34,7 +34,7 @@ import org.springframework.context.annotation.Configuration;
* @author Stephane Nicoll
* @since 1.3.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnBean(Cache.class)
@ConditionalOnMissingBean(CacheManager.class)
@Conditional(CacheCondition.class)

View File

@@ -43,7 +43,7 @@ import org.springframework.context.annotation.Configuration;
* @since 1.3.0
* @see HazelcastConfigResourceCondition
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ HazelcastInstance.class, HazelcastCacheManager.class })
@ConditionalOnMissingBean(CacheManager.class)
@Conditional(CacheCondition.class)

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -33,7 +33,7 @@ import org.springframework.core.io.Resource;
*
* @author Stephane Nicoll
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(HazelcastInstance.class)
class HazelcastJCacheCustomizationConfiguration {

View File

@@ -43,7 +43,7 @@ import org.springframework.util.CollectionUtils;
* @author Raja Kolli
* @since 1.3.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(SpringEmbeddedCacheManager.class)
@ConditionalOnMissingBean(CacheManager.class)
@Conditional(CacheCondition.class)

View File

@@ -55,7 +55,7 @@ import org.springframework.util.StringUtils;
* @author Madhura Bhave
* @since 1.3.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ Caching.class, JCacheCacheManager.class })
@ConditionalOnMissingBean(org.springframework.cache.CacheManager.class)
@Conditional({ CacheCondition.class,

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -29,7 +29,7 @@ import org.springframework.context.annotation.Configuration;
* @author Stephane Nicoll
* @since 1.3.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnMissingBean(CacheManager.class)
@Conditional(CacheCondition.class)
class NoOpCacheConfiguration {

View File

@@ -45,7 +45,7 @@ import org.springframework.data.redis.serializer.RedisSerializationContext.Seria
* @author Ryon Day
* @since 1.3.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(RedisConnectionFactory.class)
@AutoConfigureAfter(RedisAutoConfiguration.class)
@ConditionalOnBean(RedisConnectionFactory.class)

View File

@@ -31,7 +31,7 @@ import org.springframework.context.annotation.Configuration;
* @author Stephane Nicoll
* @since 1.3.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnMissingBean(CacheManager.class)
@Conditional(CacheCondition.class)
class SimpleCacheConfiguration {

View File

@@ -42,7 +42,7 @@ import org.springframework.util.StringUtils;
* @author Stephane Nicoll
* @since 1.3.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ Cluster.class })
@EnableConfigurationProperties(CassandraProperties.class)
public class CassandraAutoConfiguration {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -43,7 +43,7 @@ import org.springframework.core.Ordered;
* @author Ramnivas Laddad
* @since 2.1.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@Profile("cloud")
@AutoConfigureOrder(CloudServiceConnectorsAutoConfiguration.ORDER)
@ConditionalOnClass(CloudScanConfiguration.class)

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -31,7 +31,7 @@ import org.springframework.context.annotation.Configuration;
* @see EnableConfigurationProperties
* @see ConfigurationProperties
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@EnableConfigurationProperties
public class ConfigurationPropertiesAutoConfiguration {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -49,7 +49,7 @@ import org.springframework.util.StringUtils;
* @author Phillip Webb
* @author Eddú Meléndez
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnMissingBean(name = AbstractApplicationContext.MESSAGE_SOURCE_BEAN_NAME, search = SearchStrategy.CURRENT)
@AutoConfigureOrder(Ordered.HIGHEST_PRECEDENCE)
@Conditional(ResourceBundleCondition.class)

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -32,7 +32,7 @@ import org.springframework.core.Ordered;
* @author Phillip Webb
* @author Dave Syer
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@AutoConfigureOrder(Ordered.HIGHEST_PRECEDENCE)
public class PropertyPlaceholderAutoConfiguration {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -37,13 +37,13 @@ import org.springframework.context.annotation.Import;
* @author Yulin Qin
* @since 1.4.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ CouchbaseBucket.class, Cluster.class })
@Conditional(CouchbaseAutoConfiguration.CouchbaseCondition.class)
@EnableConfigurationProperties(CouchbaseProperties.class)
public class CouchbaseAutoConfiguration {
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnMissingBean(value = CouchbaseConfiguration.class, type = "org.springframework.data.couchbase.config.CouchbaseConfigurer")
@Import(CouchbaseConfiguration.class)
static class DefaultCouchbaseConfiguration {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -34,7 +34,7 @@ import org.springframework.dao.annotation.PersistenceExceptionTranslationPostPro
* @author Madhura Bhave
* @since 1.2.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(PersistenceExceptionTranslationPostProcessor.class)
public class PersistenceExceptionTranslationAutoConfiguration {

View File

@@ -57,7 +57,7 @@ import org.springframework.data.cassandra.core.mapping.SimpleUserTypeResolver;
* @author Madhura Bhave
* @since 1.3.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ Cluster.class, CassandraAdminOperations.class })
@EnableConfigurationProperties(CassandraProperties.class)
@AutoConfigureAfter(CassandraAutoConfiguration.class)

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -42,7 +42,7 @@ import org.springframework.data.cassandra.core.cql.session.DefaultReactiveSessio
* @author Mark Paluch
* @since 2.0.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ Cluster.class, ReactiveCassandraTemplate.class, Flux.class })
@ConditionalOnBean(Session.class)
@AutoConfigureAfter(CassandraDataAutoConfiguration.class)

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -38,7 +38,7 @@ import org.springframework.data.cassandra.repository.support.ReactiveCassandraRe
* @since 2.0.0
* @see EnableReactiveCassandraRepositories
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ ReactiveSession.class, ReactiveCassandraRepository.class })
@ConditionalOnRepositoryType(store = "cassandra", type = RepositoryType.REACTIVE)
@ConditionalOnMissingBean(ReactiveCassandraRepositoryFactoryBean.class)

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -37,7 +37,7 @@ import org.springframework.data.cassandra.repository.support.CassandraRepository
* @see EnableCassandraRepositories
* @since 1.3.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ Session.class, CassandraRepository.class })
@ConditionalOnRepositoryType(store = "cassandra", type = RepositoryType.IMPERATIVE)
@ConditionalOnMissingBean(CassandraRepositoryFactoryBean.class)

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -30,7 +30,7 @@ import org.springframework.data.couchbase.config.CouchbaseConfigurer;
*
* @author Stephane Nicoll
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(CouchbaseConfigurer.class)
@ConditionalOnBean(CouchbaseConfiguration.class)
class CouchbaseConfigurerAdapterConfiguration {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -40,7 +40,7 @@ import org.springframework.data.couchbase.repository.CouchbaseRepository;
* @author Stephane Nicoll
* @since 1.4.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ Bucket.class, CouchbaseRepository.class })
@AutoConfigureAfter({ CouchbaseAutoConfiguration.class,
ValidationAutoConfiguration.class })
@@ -49,7 +49,7 @@ import org.springframework.data.couchbase.repository.CouchbaseRepository;
SpringBootCouchbaseDataConfiguration.class })
public class CouchbaseDataAutoConfiguration {
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(Validator.class)
public static class ValidationConfiguration {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -33,7 +33,7 @@ import org.springframework.data.couchbase.repository.ReactiveCouchbaseRepository
* @author Alex Derkach
* @since 2.0.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ Bucket.class, ReactiveCouchbaseRepository.class, Flux.class })
@AutoConfigureAfter(CouchbaseDataAutoConfiguration.class)
@Import(SpringBootCouchbaseReactiveDataConfiguration.class)

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -39,7 +39,7 @@ import org.springframework.data.couchbase.repository.support.ReactiveCouchbaseRe
* @author Alex Derkach
* @since 2.0.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ Bucket.class, ReactiveCouchbaseRepository.class, Flux.class })
@ConditionalOnRepositoryType(store = "couchbase", type = RepositoryType.REACTIVE)
@ConditionalOnBean(ReactiveRepositoryOperationsMapping.class)

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -38,7 +38,7 @@ import org.springframework.data.couchbase.repository.support.CouchbaseRepository
* @author Stephane Nicoll
* @since 1.4.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ Bucket.class, CouchbaseRepository.class })
@ConditionalOnBean(RepositoryOperationsMapping.class)
@ConditionalOnRepositoryType(store = "couchbase", type = RepositoryType.IMPERATIVE)

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -38,7 +38,7 @@ import org.springframework.data.elasticsearch.client.TransportClientFactoryBean;
* @author Andy Wilkinson
* @since 1.1.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ Client.class, TransportClientFactoryBean.class })
@ConditionalOnProperty(prefix = "spring.data.elasticsearch", name = "cluster-nodes", matchIfMissing = false)
@EnableConfigurationProperties(ElasticsearchProperties.class)

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -43,7 +43,7 @@ import org.springframework.data.elasticsearch.repository.config.EnableElasticsea
* @see EnableElasticsearchRepositories
* @since 1.1.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ Client.class, ElasticsearchTemplate.class })
@AutoConfigureAfter(ElasticsearchAutoConfiguration.class)
public class ElasticsearchDataAutoConfiguration {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -37,7 +37,7 @@ import org.springframework.data.elasticsearch.repository.support.ElasticsearchRe
* @see EnableElasticsearchRepositories
* @since 1.1.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ Client.class, ElasticsearchRepository.class })
@ConditionalOnProperty(prefix = "spring.data.elasticsearch.repositories", name = "enabled", havingValue = "true", matchIfMissing = true)
@ConditionalOnMissingBean(ElasticsearchRepositoryFactoryBean.class)

View File

@@ -43,7 +43,7 @@ import org.springframework.jdbc.core.namedparam.NamedParameterJdbcOperations;
* @see EnableJdbcRepositories
*/
@SuppressWarnings("deprecation")
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnBean(NamedParameterJdbcOperations.class)
@ConditionalOnClass({ NamedParameterJdbcOperations.class,
AbstractJdbcConfiguration.class })
@@ -51,7 +51,7 @@ import org.springframework.jdbc.core.namedparam.NamedParameterJdbcOperations;
@AutoConfigureAfter(JdbcTemplateAutoConfiguration.class)
public class JdbcRepositoriesAutoConfiguration {
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnMissingBean(JdbcRepositoryConfigExtension.class)
@Import(JdbcRepositoriesAutoConfigureRegistrar.class)
static class JdbcRepositoriesConfiguration {

View File

@@ -59,7 +59,7 @@ import org.springframework.data.jpa.repository.support.JpaRepositoryFactoryBean;
* @author Josh Long
* @see EnableJpaRepositories
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnBean(DataSource.class)
@ConditionalOnClass(JpaRepository.class)
@ConditionalOnMissingBean({ JpaRepositoryFactoryBean.class,

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -33,7 +33,7 @@ import org.springframework.data.ldap.repository.support.LdapRepositoryFactoryBea
* @author Eddú Meléndez
* @since 1.5.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ LdapContext.class, LdapRepository.class })
@ConditionalOnProperty(prefix = "spring.data.ldap.repositories", name = "enabled", havingValue = "true", matchIfMissing = true)
@ConditionalOnMissingBean(LdapRepositoryFactoryBean.class)

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -72,7 +72,7 @@ import org.springframework.util.StringUtils;
* @author Christoph Strobl
* @since 1.1.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ MongoClient.class, com.mongodb.client.MongoClient.class,
MongoTemplate.class })
@Conditional(AnyMongoClientAvailable.class)

View File

@@ -35,7 +35,7 @@ import org.springframework.data.mongodb.core.mapping.MongoMappingContext;
*
* @author Madhura Bhave
*/
@Configuration
@Configuration(proxyBeanMethods = false)
class MongoDataConfiguration {
@Bean

View File

@@ -51,7 +51,7 @@ import org.springframework.data.mongodb.core.mapping.MongoMappingContext;
* @author Mark Paluch
* @since 2.0.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ MongoClient.class, ReactiveMongoTemplate.class })
@ConditionalOnBean(MongoClient.class)
@EnableConfigurationProperties(MongoProperties.class)

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -48,7 +48,7 @@ import org.springframework.data.mongodb.repository.support.ReactiveMongoReposito
* @since 2.0.0
* @see EnableReactiveMongoRepositories
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ MongoClient.class, ReactiveMongoRepository.class })
@ConditionalOnMissingBean({ ReactiveMongoRepositoryFactoryBean.class,
ReactiveMongoRepositoryConfigurationExtension.class })

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -52,7 +52,7 @@ import org.springframework.data.mongodb.repository.support.MongoRepositoryFactor
* @author Josh Long
* @see EnableMongoRepositories
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ MongoClient.class, MongoRepository.class })
@ConditionalOnMissingBean({ MongoRepositoryFactoryBean.class,
MongoRepositoryConfigurationExtension.class })

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -41,7 +41,7 @@ import org.springframework.web.context.WebApplicationContext;
*
* @author Michael Simons
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ Caffeine.class, CaffeineCacheManager.class })
@ConditionalOnMissingBean(BookmarkManager.class)
@ConditionalOnBean({ BeanFactoryBookmarkOperationAdvisor.class,

View File

@@ -55,7 +55,7 @@ import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;
* @author Kazuki Shimizu
* @since 1.4.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ SessionFactory.class, Neo4jTransactionManager.class,
PlatformTransactionManager.class })
@ConditionalOnMissingBean(SessionFactory.class)
@@ -105,41 +105,43 @@ public class Neo4jDataAutoConfiguration {
return StringUtils.toStringArray(packages);
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnWebApplication(type = Type.SERVLET)
@ConditionalOnClass({ WebMvcConfigurer.class, OpenSessionInViewInterceptor.class })
@ConditionalOnMissingBean(OpenSessionInViewInterceptor.class)
@ConditionalOnProperty(prefix = "spring.data.neo4j", name = "open-in-view", havingValue = "true", matchIfMissing = true)
protected static class Neo4jWebConfiguration {
@Configuration
protected static class Neo4jWebMvcConfiguration implements WebMvcConfigurer {
private static final Log logger = LogFactory.getLog(Neo4jWebConfiguration.class);
private static final Log logger = LogFactory
.getLog(Neo4jWebMvcConfiguration.class);
private final Neo4jProperties neo4jProperties;
private final Neo4jProperties neo4jProperties;
protected Neo4jWebConfiguration(Neo4jProperties neo4jProperties) {
this.neo4jProperties = neo4jProperties;
}
protected Neo4jWebMvcConfiguration(Neo4jProperties neo4jProperties) {
this.neo4jProperties = neo4jProperties;
@Bean
public OpenSessionInViewInterceptor neo4jOpenSessionInViewInterceptor() {
if (this.neo4jProperties.getOpenInView() == null) {
logger.warn("spring.data.neo4j.open-in-view is enabled by default."
+ "Therefore, database queries may be performed during view "
+ "rendering. Explicitly configure "
+ "spring.data.neo4j.open-in-view to disable this warning");
}
return new OpenSessionInViewInterceptor();
}
@Bean
public OpenSessionInViewInterceptor neo4jOpenSessionInViewInterceptor() {
if (this.neo4jProperties.getOpenInView() == null) {
logger.warn("spring.data.neo4j.open-in-view is enabled by default."
+ "Therefore, database queries may be performed during view "
+ "rendering. Explicitly configure "
+ "spring.data.neo4j.open-in-view to disable this warning");
@Bean
public WebMvcConfigurer neo4jOpenSessionInViewInterceptorConfigurer(
OpenSessionInViewInterceptor interceptor) {
return new WebMvcConfigurer() {
@Override
public void addInterceptors(InterceptorRegistry registry) {
registry.addWebRequestInterceptor(interceptor);
}
return new OpenSessionInViewInterceptor();
}
@Override
public void addInterceptors(InterceptorRegistry registry) {
registry.addWebRequestInterceptor(neo4jOpenSessionInViewInterceptor());
}
};
}
}

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -48,7 +48,7 @@ import org.springframework.data.neo4j.repository.support.Neo4jRepositoryFactoryB
* @since 1.4.0
* @see EnableNeo4jRepositories
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ Neo4jSession.class, Neo4jRepository.class })
@ConditionalOnMissingBean({ Neo4jRepositoryFactoryBean.class,
Neo4jRepositoryConfigurationExtension.class })

View File

@@ -43,7 +43,7 @@ import org.springframework.util.StringUtils;
* @author Mark Paluch
* @author Stephane Nicoll
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ GenericObjectPool.class, JedisConnection.class, Jedis.class })
class JedisConnectionConfiguration extends RedisConnectionConfiguration {

View File

@@ -44,7 +44,7 @@ import org.springframework.util.StringUtils;
* @author Mark Paluch
* @author Andy Wilkinson
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(RedisClient.class)
class LettuceConnectionConfiguration extends RedisConnectionConfiguration {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -43,7 +43,7 @@ import org.springframework.data.redis.core.StringRedisTemplate;
* @author Marco Aust
* @author Mark Paluch
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(RedisOperations.class)
@EnableConfigurationProperties(RedisProperties.class)
@Import({ LettuceConnectionConfiguration.class, JedisConnectionConfiguration.class })

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -39,7 +39,7 @@ import org.springframework.data.redis.serializer.RedisSerializationContext;
* @author Stephane Nicoll
* @since 2.0.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ ReactiveRedisConnectionFactory.class, ReactiveRedisTemplate.class,
Flux.class })
@AutoConfigureAfter(RedisAutoConfiguration.class)

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -37,7 +37,7 @@ import org.springframework.data.redis.repository.support.RedisRepositoryFactoryB
* @see EnableRedisRepositories
* @since 1.4.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(EnableRedisRepositories.class)
@ConditionalOnBean(RedisConnectionFactory.class)
@ConditionalOnProperty(prefix = "spring.data.redis.repositories", name = "enabled", havingValue = "true", matchIfMissing = true)

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -46,7 +46,7 @@ import org.springframework.data.rest.webmvc.config.RepositoryRestMvcConfiguratio
* @author Andy Wilkinson
* @since 1.1.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnWebApplication(type = Type.SERVLET)
@ConditionalOnMissingBean(RepositoryRestMvcConfiguration.class)
@ConditionalOnClass(RepositoryRestMvcConfiguration.class)

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -42,7 +42,7 @@ import org.springframework.data.solr.repository.support.SolrRepositoryFactoryBea
* @author Oliver Gierke
* @since 1.1.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ SolrClient.class, SolrRepository.class })
@ConditionalOnMissingBean({ SolrRepositoryFactoryBean.class,
SolrRepositoryConfigExtension.class })

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -44,7 +44,7 @@ import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;
* @author Vedran Pavic
* @since 1.2.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@EnableSpringDataWebSupport
@ConditionalOnWebApplication(type = Type.SERVLET)
@ConditionalOnClass({ PageableHandlerMethodArgumentResolver.class,

View File

@@ -43,7 +43,7 @@ import org.springframework.util.Assert;
* @author Stephane Nicoll
* @since 1.4.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(JestClient.class)
@EnableConfigurationProperties(JestProperties.class)
@AutoConfigureAfter(GsonAutoConfiguration.class)

View File

@@ -41,7 +41,7 @@ import org.springframework.context.annotation.Configuration;
* @author Brian Clozel
* @since 2.1.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(RestClient.class)
@EnableConfigurationProperties(RestClientProperties.class)
public class RestClientAutoConfiguration {
@@ -73,7 +73,7 @@ public class RestClientAutoConfiguration {
return builder;
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(RestHighLevelClient.class)
public static class RestHighLevelClientConfiguration {

View File

@@ -80,7 +80,7 @@ import org.springframework.util.StringUtils;
* @since 1.1.0
*/
@SuppressWarnings("deprecation")
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(Flyway.class)
@ConditionalOnBean(DataSource.class)
@ConditionalOnProperty(prefix = "spring.flyway", name = "enabled", matchIfMissing = true)
@@ -100,7 +100,7 @@ public class FlywayAutoConfiguration {
return new FlywaySchemaManagementProvider(flyways);
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnMissingBean(Flyway.class)
@EnableConfigurationProperties({ DataSourceProperties.class, FlywayProperties.class })
public static class FlywayConfiguration {
@@ -274,7 +274,7 @@ public class FlywayAutoConfiguration {
* Additional configuration to ensure that {@link EntityManagerFactory} beans
* depend on the {@code flywayInitializer} bean.
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(LocalContainerEntityManagerFactoryBean.class)
@ConditionalOnBean(AbstractEntityManagerFactoryBean.class)
protected static class FlywayInitializerJpaDependencyConfiguration
@@ -290,7 +290,7 @@ public class FlywayAutoConfiguration {
* Additional configuration to ensure that {@link JdbcOperations} beans depend on
* the {@code flywayInitializer} bean.
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(JdbcOperations.class)
@ConditionalOnBean(JdbcOperations.class)
protected static class FlywayInitializerJdbcOperationsDependencyConfiguration
@@ -307,7 +307,7 @@ public class FlywayAutoConfiguration {
* Additional configuration to ensure that {@link NamedParameterJdbcOperations}
* beans depend on the {@code flywayInitializer} bean.
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(NamedParameterJdbcOperations.class)
@ConditionalOnBean(NamedParameterJdbcOperations.class)
protected static class FlywayInitializerNamedParameterJdbcOperationsDependencyConfiguration
@@ -325,7 +325,7 @@ public class FlywayAutoConfiguration {
* Additional configuration to ensure that {@link EntityManagerFactory} beans depend
* on the {@code flyway} bean.
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(LocalContainerEntityManagerFactoryBean.class)
@ConditionalOnBean(AbstractEntityManagerFactoryBean.class)
protected static class FlywayJpaDependencyConfiguration
@@ -341,7 +341,7 @@ public class FlywayAutoConfiguration {
* Additional configuration to ensure that {@link JdbcOperations} beans depend on the
* {@code flyway} bean.
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(JdbcOperations.class)
@ConditionalOnBean(JdbcOperations.class)
protected static class FlywayJdbcOperationsDependencyConfiguration
@@ -357,7 +357,7 @@ public class FlywayAutoConfiguration {
* Additional configuration to ensure that {@link NamedParameterJdbcOperations} beans
* depend on the {@code flyway} bean.
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(NamedParameterJdbcOperations.class)
@ConditionalOnBean(NamedParameterJdbcOperations.class)
protected static class FlywayNamedParameterJdbcOperationsDependencyConfiguration

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -41,7 +41,7 @@ import org.springframework.ui.freemarker.FreeMarkerConfigurationFactory;
* @author Kazuki Shimizu
* @since 1.1.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ freemarker.template.Configuration.class,
FreeMarkerConfigurationFactory.class })
@EnableConfigurationProperties(FreeMarkerProperties.class)

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -28,7 +28,7 @@ import org.springframework.ui.freemarker.FreeMarkerConfigurationFactoryBean;
* @author Brian Clozel
* @author Andy Wilkinson
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnNotWebApplication
class FreeMarkerNonWebConfiguration extends AbstractFreeMarkerConfiguration {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -33,7 +33,7 @@ import org.springframework.web.reactive.result.view.freemarker.FreeMarkerViewRes
* @author Brian Clozel
* @author Andy Wilkinson
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnWebApplication(type = ConditionalOnWebApplication.Type.REACTIVE)
@AutoConfigureAfter(WebFluxAutoConfiguration.class)
class FreeMarkerReactiveWebConfiguration extends AbstractFreeMarkerConfiguration {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -41,7 +41,7 @@ import org.springframework.web.servlet.view.freemarker.FreeMarkerViewResolver;
* @author Brian Clozel
* @author Andy Wilkinson
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnWebApplication(type = ConditionalOnWebApplication.Type.SERVLET)
@ConditionalOnClass({ Servlet.class, FreeMarkerConfigurer.class })
@AutoConfigureAfter(WebMvcAutoConfiguration.class)

View File

@@ -57,7 +57,7 @@ import org.springframework.web.servlet.view.groovy.GroovyMarkupViewResolver;
* @author Brian Clozel
* @since 1.1.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(MarkupTemplateEngine.class)
@AutoConfigureAfter(WebMvcAutoConfiguration.class)
@EnableConfigurationProperties(GroovyTemplateProperties.class)
@@ -66,7 +66,7 @@ public class GroovyTemplateAutoConfiguration {
private static final Log logger = LogFactory
.getLog(GroovyTemplateAutoConfiguration.class);
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(GroovyMarkupConfigurer.class)
public static class GroovyMarkupConfiguration {
@@ -132,7 +132,7 @@ public class GroovyTemplateAutoConfiguration {
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ Servlet.class, LocaleContextHolder.class,
UrlBasedViewResolver.class })
@ConditionalOnWebApplication(type = Type.SERVLET)

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -37,7 +37,7 @@ import org.springframework.core.Ordered;
* @author Ivan Golovko
* @since 1.2.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(Gson.class)
@EnableConfigurationProperties(GsonProperties.class)
public class GsonAutoConfiguration {

View File

@@ -36,7 +36,7 @@ import org.springframework.context.annotation.Configuration;
* @author Stephane Nicoll
* @since 1.3.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnWebApplication(type = Type.SERVLET)
@ConditionalOnClass(WebServlet.class)
@ConditionalOnProperty(prefix = "spring.h2.console", name = "enabled", havingValue = "true", matchIfMissing = false)

View File

@@ -48,7 +48,7 @@ import org.springframework.web.bind.annotation.RequestMapping;
* @author Andy Wilkinson
* @since 1.1.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ EntityModel.class, RequestMapping.class, Plugin.class })
@ConditionalOnWebApplication
@AutoConfigureAfter({ WebMvcAutoConfiguration.class, JacksonAutoConfiguration.class,
@@ -58,7 +58,7 @@ import org.springframework.web.bind.annotation.RequestMapping;
@Import(HypermediaHttpMessageConverterConfiguration.class)
public class HypermediaAutoConfiguration {
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnMissingBean(LinkDiscoverers.class)
@ConditionalOnClass(ObjectMapper.class)
@EnableHypermediaSupport(type = HypermediaType.HAL)
@@ -66,7 +66,7 @@ public class HypermediaAutoConfiguration {
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnMissingBean(EntityLinks.class)
@EnableEntityLinks
protected static class EntityLinksConfiguration {

View File

@@ -42,7 +42,7 @@ import org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandl
*
* @author Andy Wilkinson
*/
@Configuration
@Configuration(proxyBeanMethods = false)
public class HypermediaHttpMessageConverterConfiguration {
@Bean

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -34,7 +34,7 @@ import org.springframework.context.annotation.Import;
* @since 1.3.0
* @see HazelcastConfigResourceCondition
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(HazelcastInstance.class)
@EnableConfigurationProperties(HazelcastProperties.class)
@Import({ HazelcastClientConfiguration.class, HazelcastServerConfiguration.class })

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -36,14 +36,14 @@ import org.springframework.core.io.Resource;
* @author Vedran Pavic
* @author Stephane Nicoll
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(HazelcastClient.class)
@ConditionalOnMissingBean(HazelcastInstance.class)
class HazelcastClientConfiguration {
static final String CONFIG_SYSTEM_PROPERTY = "hazelcast.client.config";
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnMissingBean(ClientConfig.class)
@Conditional(ConfigAvailableCondition.class)
static class HazelcastClientConfigFileConfiguration {
@@ -60,7 +60,7 @@ class HazelcastClientConfiguration {
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnSingleCandidate(ClientConfig.class)
static class HazelcastClientConfigConfiguration {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -39,7 +39,7 @@ import org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean;
* @author Stephane Nicoll
* @since 1.3.2
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ HazelcastInstance.class,
LocalContainerEntityManagerFactoryBean.class })
@AutoConfigureAfter({ HazelcastAutoConfiguration.class,

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -35,13 +35,13 @@ import org.springframework.core.io.Resource;
* @author Stephane Nicoll
* @author Vedran Pavic
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnMissingBean(HazelcastInstance.class)
class HazelcastServerConfiguration {
static final String CONFIG_SYSTEM_PROPERTY = "hazelcast.config";
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnMissingBean(Config.class)
@Conditional(ConfigAvailableCondition.class)
static class HazelcastServerConfigFileConfiguration {
@@ -58,7 +58,7 @@ class HazelcastServerConfiguration {
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnSingleCandidate(Config.class)
static class HazelcastServerConfigConfiguration {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -37,11 +37,11 @@ import org.springframework.http.converter.json.MappingJackson2HttpMessageConvert
* @author Eddú Meléndez
* @since 1.2.2
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(Gson.class)
class GsonHttpMessageConvertersConfiguration {
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnBean(Gson.class)
@Conditional(PreferGsonOrJacksonAndJsonbUnavailableCondition.class)
protected static class GsonHttpMessageConverterConfiguration {

View File

@@ -51,7 +51,7 @@ import org.springframework.http.converter.StringHttpMessageConverter;
* @author Stephane Nicoll
* @author Eddú Meléndez
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(HttpMessageConverter.class)
@Conditional(NotReactiveWebApplicationCondition.class)
@AutoConfigureAfter({ GsonAutoConfiguration.class, JacksonAutoConfiguration.class,
@@ -71,7 +71,7 @@ public class HttpMessageConvertersAutoConfiguration {
converters.orderedStream().collect(Collectors.toList()));
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(StringHttpMessageConverter.class)
@EnableConfigurationProperties(HttpProperties.class)
protected static class StringHttpMessageConverterConfiguration {

View File

@@ -35,10 +35,10 @@ import org.springframework.http.converter.xml.MappingJackson2XmlHttpMessageConve
* @author Andy Wilkinson
* @since 1.2.2
*/
@Configuration
@Configuration(proxyBeanMethods = false)
class JacksonHttpMessageConvertersConfiguration {
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(ObjectMapper.class)
@ConditionalOnBean(ObjectMapper.class)
@ConditionalOnProperty(name = HttpMessageConvertersAutoConfiguration.PREFERRED_MAPPER_PROPERTY, havingValue = "jackson", matchIfMissing = true)
@@ -55,7 +55,7 @@ class JacksonHttpMessageConvertersConfiguration {
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(XmlMapper.class)
@ConditionalOnBean(Jackson2ObjectMapperBuilder.class)
protected static class MappingJackson2XmlHttpMessageConverterConfiguration {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -36,11 +36,11 @@ import org.springframework.http.converter.json.MappingJackson2HttpMessageConvert
* @author Eddú Meléndez
* @since 2.0.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(Jsonb.class)
class JsonbHttpMessageConvertersConfiguration {
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnBean(Jsonb.class)
@Conditional(PreferJsonbOrMissingJacksonAndGsonCondition.class)
protected static class JsonbHttpMessageConverterConfiguration {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -42,14 +42,14 @@ import org.springframework.util.MimeType;
* @author Brian Clozel
* @since 2.0.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(CodecConfigurer.class)
@AutoConfigureAfter(JacksonAutoConfiguration.class)
public class CodecsAutoConfiguration {
private static final MimeType[] EMPTY_MIME_TYPES = {};
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(ObjectMapper.class)
static class JacksonCodecConfiguration {
@@ -68,7 +68,7 @@ public class CodecsAutoConfiguration {
}
@Configuration
@Configuration(proxyBeanMethods = false)
@EnableConfigurationProperties(HttpProperties.class)
static class LoggingCodecConfiguration {

View File

@@ -37,7 +37,7 @@ import org.springframework.context.annotation.Configuration;
* @author Eddú Meléndez
* @since 2.0.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(InfluxDB.class)
@EnableConfigurationProperties(InfluxDbProperties.class)
public class InfluxDbAutoConfiguration {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -48,7 +48,7 @@ import org.springframework.core.type.AnnotatedTypeMetadata;
* @author Madhura Bhave
* @since 1.4.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@EnableConfigurationProperties(ProjectInfoProperties.class)
public class ProjectInfoAutoConfiguration {

View File

@@ -55,7 +55,7 @@ import org.springframework.util.StringUtils;
* @author Madhura Bhave
* @since 1.1.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(EnableIntegration.class)
@EnableConfigurationProperties(IntegrationProperties.class)
@AutoConfigureAfter({ DataSourceAutoConfiguration.class, JmxAutoConfiguration.class })
@@ -64,7 +64,7 @@ public class IntegrationAutoConfiguration {
/**
* Basic Spring Integration configuration.
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@EnableIntegration
protected static class IntegrationConfiguration {
@@ -73,7 +73,7 @@ public class IntegrationAutoConfiguration {
/**
* Spring Integration JMX configuration.
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(EnableIntegrationMBeanExport.class)
@ConditionalOnMissingBean(value = IntegrationMBeanExporter.class, search = SearchStrategy.CURRENT)
@ConditionalOnBean(MBeanServer.class)
@@ -99,12 +99,12 @@ public class IntegrationAutoConfiguration {
/**
* Integration management configuration.
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(EnableIntegrationManagement.class)
@ConditionalOnMissingBean(value = IntegrationManagementConfigurer.class, name = IntegrationManagementConfigurer.MANAGEMENT_CONFIGURER_NAME, search = SearchStrategy.CURRENT)
protected static class IntegrationManagementConfiguration {
@Configuration
@Configuration(proxyBeanMethods = false)
@EnableIntegrationManagement(defaultCountsEnabled = "true")
protected static class EnableIntegrationManagementConfiguration {
@@ -115,7 +115,7 @@ public class IntegrationAutoConfiguration {
/**
* Integration component scan configuration.
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnMissingBean(GatewayProxyFactoryBean.class)
@Import(IntegrationAutoConfigurationScanRegistrar.class)
protected static class IntegrationComponentScanConfiguration {
@@ -125,7 +125,7 @@ public class IntegrationAutoConfiguration {
/**
* Integration JDBC configuration.
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(JdbcMessageStore.class)
@ConditionalOnSingleCandidate(DataSource.class)
protected static class IntegrationJdbcConfiguration {

View File

@@ -78,7 +78,7 @@ import org.springframework.util.ReflectionUtils;
* @author Eddú Meléndez
* @since 1.1.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(ObjectMapper.class)
public class JacksonAutoConfiguration {
@@ -95,7 +95,7 @@ public class JacksonAutoConfiguration {
return new JsonComponentModule();
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(Jackson2ObjectMapperBuilder.class)
static class JacksonObjectMapperConfiguration {
@@ -108,7 +108,7 @@ public class JacksonAutoConfiguration {
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ Jackson2ObjectMapperBuilder.class, DateTime.class,
DateTimeSerializer.class, JacksonJodaDateFormat.class })
static class JodaDateTimeJacksonConfiguration {
@@ -155,7 +155,7 @@ public class JacksonAutoConfiguration {
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(ParameterNamesModule.class)
static class ParameterNamesModuleConfiguration {
@@ -167,7 +167,7 @@ public class JacksonAutoConfiguration {
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(Jackson2ObjectMapperBuilder.class)
static class JacksonObjectMapperBuilderConfiguration {
@@ -191,7 +191,7 @@ public class JacksonAutoConfiguration {
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(Jackson2ObjectMapperBuilder.class)
@EnableConfigurationProperties(JacksonProperties.class)
static class Jackson2ObjectMapperBuilderCustomizerConfiguration {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -47,14 +47,14 @@ import org.springframework.jdbc.datasource.embedded.EmbeddedDatabaseType;
* @author Stephane Nicoll
* @author Kazuki Shimizu
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ DataSource.class, EmbeddedDatabaseType.class })
@EnableConfigurationProperties(DataSourceProperties.class)
@Import({ DataSourcePoolMetadataProvidersConfiguration.class,
DataSourceInitializationConfiguration.class })
public class DataSourceAutoConfiguration {
@Configuration
@Configuration(proxyBeanMethods = false)
@Conditional(EmbeddedDatabaseCondition.class)
@ConditionalOnMissingBean({ DataSource.class, XADataSource.class })
@Import(EmbeddedDataSourceConfiguration.class)
@@ -62,7 +62,7 @@ public class DataSourceAutoConfiguration {
}
@Configuration
@Configuration(proxyBeanMethods = false)
@Conditional(PooledDataSourceCondition.class)
@ConditionalOnMissingBean({ DataSource.class, XADataSource.class })
@Import({ DataSourceConfiguration.Hikari.class, DataSourceConfiguration.Tomcat.class,

View File

@@ -47,7 +47,7 @@ abstract class DataSourceConfiguration {
/**
* Tomcat Pool DataSource configuration.
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(org.apache.tomcat.jdbc.pool.DataSource.class)
@ConditionalOnMissingBean(DataSource.class)
@ConditionalOnProperty(name = "spring.datasource.type", havingValue = "org.apache.tomcat.jdbc.pool.DataSource", matchIfMissing = true)
@@ -74,7 +74,7 @@ abstract class DataSourceConfiguration {
/**
* Hikari DataSource configuration.
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(HikariDataSource.class)
@ConditionalOnMissingBean(DataSource.class)
@ConditionalOnProperty(name = "spring.datasource.type", havingValue = "com.zaxxer.hikari.HikariDataSource", matchIfMissing = true)
@@ -96,7 +96,7 @@ abstract class DataSourceConfiguration {
/**
* DBCP DataSource configuration.
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(org.apache.commons.dbcp2.BasicDataSource.class)
@ConditionalOnMissingBean(DataSource.class)
@ConditionalOnProperty(name = "spring.datasource.type", havingValue = "org.apache.commons.dbcp2.BasicDataSource", matchIfMissing = true)
@@ -115,7 +115,7 @@ abstract class DataSourceConfiguration {
/**
* Generic DataSource configuration.
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnMissingBean(DataSource.class)
@ConditionalOnProperty(name = "spring.datasource.type")
static class Generic {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -29,7 +29,7 @@ import org.springframework.core.type.AnnotationMetadata;
*
* @author Stephane Nicoll
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@Import({ DataSourceInitializerInvoker.class,
DataSourceInitializationConfiguration.Registrar.class })
class DataSourceInitializationConfiguration {

View File

@@ -41,13 +41,13 @@ import org.springframework.jmx.export.MBeanExporter;
*
* @author Stephane Nicoll
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnProperty(prefix = "spring.jmx", name = "enabled", havingValue = "true", matchIfMissing = true)
class DataSourceJmxConfiguration {
private static final Log logger = LogFactory.getLog(DataSourceJmxConfiguration.class);
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(HikariDataSource.class)
@ConditionalOnSingleCandidate(DataSource.class)
static class Hikari {
@@ -73,7 +73,7 @@ class DataSourceJmxConfiguration {
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnProperty(prefix = "spring.datasource", name = "jmx-enabled")
@ConditionalOnClass(DataSourceProxy.class)
@ConditionalOnSingleCandidate(DataSource.class)

View File

@@ -42,13 +42,13 @@ import org.springframework.transaction.PlatformTransactionManager;
* @author Andy Wilkinson
* @author Kazuki Shimizu
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ JdbcTemplate.class, PlatformTransactionManager.class })
@AutoConfigureOrder(Ordered.LOWEST_PRECEDENCE)
@EnableConfigurationProperties(DataSourceProperties.class)
public class DataSourceTransactionManagerAutoConfiguration {
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnSingleCandidate(DataSource.class)
static class DataSourceTransactionManagerConfiguration {

View File

@@ -31,7 +31,7 @@ import org.springframework.jdbc.datasource.embedded.EmbeddedDatabaseBuilder;
* @author Stephane Nicoll
* @see DataSourceAutoConfiguration
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@EnableConfigurationProperties(DataSourceProperties.class)
public class EmbeddedDataSourceConfiguration implements BeanClassLoaderAware {

View File

@@ -43,14 +43,14 @@ import org.springframework.jdbc.core.namedparam.NamedParameterJdbcTemplate;
* @author Kazuki Shimizu
* @since 1.4.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ DataSource.class, JdbcTemplate.class })
@ConditionalOnSingleCandidate(DataSource.class)
@AutoConfigureAfter(DataSourceAutoConfiguration.class)
@EnableConfigurationProperties(JdbcProperties.class)
public class JdbcTemplateAutoConfiguration {
@Configuration
@Configuration(proxyBeanMethods = false)
static class JdbcTemplateConfiguration {
@Bean
@@ -71,7 +71,7 @@ public class JdbcTemplateAutoConfiguration {
}
@Configuration
@Configuration(proxyBeanMethods = false)
@Import(JdbcTemplateConfiguration.class)
static class NamedParameterJdbcTemplateConfiguration {

View File

@@ -40,7 +40,7 @@ import org.springframework.jmx.support.JmxUtils;
* @author Andy Wilkinson
* @since 1.2.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@AutoConfigureBefore({ XADataSourceAutoConfiguration.class,
DataSourceAutoConfiguration.class })
@ConditionalOnClass({ DataSource.class, EmbeddedDatabaseType.class })

View File

@@ -52,7 +52,7 @@ import org.springframework.util.StringUtils;
* @author Madhura Bhave
* @since 1.2.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@AutoConfigureBefore(DataSourceAutoConfiguration.class)
@EnableConfigurationProperties(DataSourceProperties.class)
@ConditionalOnClass({ DataSource.class, TransactionManager.class,

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -35,10 +35,10 @@ import org.springframework.context.annotation.Configuration;
* @author Stephane Nicoll
* @since 1.2.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
public class DataSourcePoolMetadataProvidersConfiguration {
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(org.apache.tomcat.jdbc.pool.DataSource.class)
static class TomcatDataSourcePoolMetadataProviderConfiguration {
@@ -56,7 +56,7 @@ public class DataSourcePoolMetadataProvidersConfiguration {
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(HikariDataSource.class)
static class HikariPoolDataSourceMetadataProviderConfiguration {
@@ -74,7 +74,7 @@ public class DataSourcePoolMetadataProvidersConfiguration {
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(BasicDataSource.class)
static class CommonsDbcp2PoolDataSourceMetadataProviderConfiguration {

View File

@@ -76,7 +76,7 @@ import org.springframework.web.filter.RequestContextFilter;
* @author Eddú Meléndez
* @author Stephane Nicoll
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ SpringComponentProvider.class, ServletRegistration.class })
@ConditionalOnBean(type = "org.glassfish.jersey.server.ResourceConfig")
@ConditionalOnWebApplication(type = Type.SERVLET)
@@ -203,7 +203,7 @@ public class JerseyAutoConfiguration implements ServletContextAware {
@ConditionalOnClass(JacksonFeature.class)
@ConditionalOnSingleCandidate(ObjectMapper.class)
@Configuration
@Configuration(proxyBeanMethods = false)
static class JacksonResourceConfigCustomizer {
private static final String JAXB_ANNOTATION_INTROSPECTOR_CLASS_NAME = "com.fasterxml.jackson.module.jaxb.JaxbAnnotationIntrospector";

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -40,7 +40,7 @@ import org.springframework.transaction.jta.JtaTransactionManager;
* @author Stephane Nicoll
* @since 1.2.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(EnableJms.class)
class JmsAnnotationDrivenConfiguration {
@@ -84,14 +84,14 @@ class JmsAnnotationDrivenConfiguration {
return factory;
}
@Configuration
@Configuration(proxyBeanMethods = false)
@EnableJms
@ConditionalOnMissingBean(name = JmsListenerConfigUtils.JMS_LISTENER_ANNOTATION_PROCESSOR_BEAN_NAME)
protected static class EnableJmsConfiguration {
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnJndi
protected static class JndiConfiguration {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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.
@@ -45,14 +45,14 @@ import org.springframework.jms.support.destination.DestinationResolver;
* @author Greg Turnquist
* @author Stephane Nicoll
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ Message.class, JmsTemplate.class })
@ConditionalOnBean(ConnectionFactory.class)
@EnableConfigurationProperties(JmsProperties.class)
@Import(JmsAnnotationDrivenConfiguration.class)
public class JmsAutoConfiguration {
@Configuration
@Configuration(proxyBeanMethods = false)
protected static class JmsTemplateConfiguration {
private final JmsProperties properties;
@@ -102,7 +102,7 @@ public class JmsAutoConfiguration {
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(JmsMessagingTemplate.class)
@Import(JmsTemplateConfiguration.class)
protected static class MessagingTemplateConfiguration {

View File

@@ -43,7 +43,7 @@ import org.springframework.util.StringUtils;
* @author Phillip Webb
* @since 1.2.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@AutoConfigureBefore(JmsAutoConfiguration.class)
@ConditionalOnClass(JmsTemplate.class)
@ConditionalOnMissingBean(ConnectionFactory.class)

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -41,7 +41,7 @@ import org.springframework.context.annotation.Import;
* @author Phillip Webb
* @since 1.1.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@AutoConfigureBefore(JmsAutoConfiguration.class)
@AutoConfigureAfter({ JndiConnectionFactoryAutoConfiguration.class })
@ConditionalOnClass({ ConnectionFactory.class, ActiveMQConnectionFactory.class })

View File

@@ -45,11 +45,11 @@ import org.springframework.jms.connection.CachingConnectionFactory;
* @author Aurélien Leboulanger
* @since 1.1.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnMissingBean(ConnectionFactory.class)
class ActiveMQConnectionFactoryConfiguration {
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(CachingConnectionFactory.class)
@ConditionalOnProperty(prefix = "spring.activemq.pool", name = "enabled", havingValue = "false", matchIfMissing = true)
static class SimpleConnectionFactoryConfiguration {
@@ -92,7 +92,7 @@ class ActiveMQConnectionFactoryConfiguration {
}
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ JmsPoolConnectionFactory.class, PooledObject.class })
static class PooledConnectionFactoryConfiguration {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -41,7 +41,7 @@ import org.springframework.context.annotation.Primary;
* @author Aurélien Leboulanger
* @since 1.2.0
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(TransactionManager.class)
@ConditionalOnBean(XAConnectionFactoryWrapper.class)
@ConditionalOnMissingBean(ConnectionFactory.class)

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -43,7 +43,7 @@ import org.springframework.context.annotation.Import;
* @since 1.3.0
* @see ArtemisProperties
*/
@Configuration
@Configuration(proxyBeanMethods = false)
@AutoConfigureBefore(JmsAutoConfiguration.class)
@AutoConfigureAfter({ JndiConnectionFactoryAutoConfiguration.class })
@ConditionalOnClass({ ConnectionFactory.class, ActiveMQConnectionFactory.class })

Some files were not shown because too many files have changed in this diff Show More