Replace all Spring @Configuration annotations with Spring Boot's @SpringBootConfiguration annotation in the SBDG auto-configuration classes.

This commit is contained in:
John Blum
2021-08-19 14:48:59 -07:00
parent 1ab774daba
commit a9594d4bad
16 changed files with 49 additions and 43 deletions

View File

@@ -21,6 +21,7 @@ import org.apache.geode.cache.Cache;
import org.apache.geode.cache.GemFireCache;
import org.apache.geode.cache.client.ClientCache;
import org.springframework.boot.SpringBootConfiguration;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.context.annotation.Bean;
@@ -43,16 +44,16 @@ import org.springframework.util.StringUtils;
* @see org.apache.geode.cache.Cache
* @see org.apache.geode.cache.GemFireCache
* @see org.apache.geode.cache.client.ClientCache
* @see org.springframework.boot.SpringBootConfiguration
* @see org.springframework.boot.autoconfigure.EnableAutoConfiguration
* @see org.springframework.context.annotation.Bean
* @see org.springframework.context.annotation.Configuration
* @see org.springframework.core.env.Environment
* @see org.springframework.data.gemfire.CacheFactoryBean
* @see org.springframework.data.gemfire.config.annotation.ClientCacheConfigurer
* @see org.springframework.data.gemfire.config.annotation.PeerCacheConfigurer
* @since 1.0.0
*/
@Configuration
@SpringBootConfiguration
@ConditionalOnClass({ CacheFactoryBean.class, GemFireCache.class })
@SuppressWarnings("unused")
public class CacheNameAutoConfiguration {

View File

@@ -25,6 +25,7 @@ import javax.annotation.PostConstruct;
import org.apache.geode.cache.GemFireCache;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.SpringBootConfiguration;
import org.springframework.boot.autoconfigure.AutoConfigureAfter;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.cache.CacheManagerCustomizers;
@@ -50,24 +51,24 @@ import org.springframework.util.StringUtils;
* @author John Blum
* @see javax.annotation.PostConstruct
* @see org.apache.geode.cache.GemFireCache
* @see org.springframework.boot.SpringBootConfiguration
* @see org.springframework.boot.autoconfigure.EnableAutoConfiguration
* @see org.springframework.boot.autoconfigure.cache.CacheManagerCustomizers
* @see org.springframework.boot.autoconfigure.cache.CacheProperties
* @see org.springframework.cache.CacheManager
* @see org.springframework.context.annotation.Configuration
* @see org.springframework.data.gemfire.cache.GemfireCacheManager
* @see org.springframework.data.gemfire.cache.config.EnableGemfireCaching
* @see org.springframework.geode.boot.autoconfigure.ClientCacheAutoConfiguration
* @since 1.0.0
*/
@Configuration
@SpringBootConfiguration
@AutoConfigureAfter(ClientCacheAutoConfiguration.class)
@Conditional(CachingProviderAutoConfiguration.SpringCacheTypeCondition.class)
@ConditionalOnBean(GemFireCache.class)
@ConditionalOnClass({ GemfireCacheManager.class, GemFireCache.class })
@ConditionalOnMissingBean(CacheManager.class)
@EnableGemfireCaching
@SuppressWarnings("all")
@SuppressWarnings("unused")
public class CachingProviderAutoConfiguration {
protected static final Set<String> SPRING_CACHE_TYPES = asSet("gemfire", "geode");

View File

@@ -24,6 +24,7 @@ import org.apache.geode.cache.GemFireCache;
import org.apache.geode.cache.client.ClientCache;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.SpringBootConfiguration;
import org.springframework.boot.autoconfigure.AutoConfigureBefore;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.condition.AllNestedConditions;
@@ -60,6 +61,7 @@ import org.slf4j.LoggerFactory;
* @see org.apache.geode.cache.GemFireCache
* @see org.apache.geode.cache.client.ClientCache
* @see org.springframework.boot.SpringApplication
* @see org.springframework.boot.SpringBootConfiguration
* @see org.springframework.boot.autoconfigure.AutoConfigureBefore
* @see org.springframework.boot.autoconfigure.EnableAutoConfiguration
* @see org.springframework.boot.autoconfigure.condition.AllNestedConditions
@@ -71,7 +73,6 @@ import org.slf4j.LoggerFactory;
* @see org.springframework.boot.cloud.CloudPlatform
* @see org.springframework.boot.env.EnvironmentPostProcessor
* @see org.springframework.context.annotation.Conditional
* @see org.springframework.context.annotation.Configuration
* @see org.springframework.core.env.ConfigurableEnvironment
* @see org.springframework.core.env.Environment
* @see org.springframework.core.env.PropertySource
@@ -85,7 +86,7 @@ import org.slf4j.LoggerFactory;
* @see org.springframework.geode.core.env.support.User
* @since 1.0.0
*/
@Configuration
@SpringBootConfiguration
@AutoConfigureBefore(ClientCacheAutoConfiguration.class)
@Conditional(ClientSecurityAutoConfiguration.EnableSecurityCondition.class)
@ConditionalOnClass({ ClientCacheFactoryBean.class, ClientCache.class })

View File

@@ -17,11 +17,11 @@ package org.springframework.geode.boot.autoconfigure;
import org.apache.geode.cache.client.ClientCache;
import org.springframework.boot.SpringBootConfiguration;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.context.annotation.Conditional;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Import;
import org.springframework.data.gemfire.client.ClientCacheFactoryBean;
import org.springframework.data.gemfire.config.annotation.EnableContinuousQueries;
@@ -34,10 +34,10 @@ import org.springframework.geode.config.annotation.ClusterAvailableConfiguration
*
* @author John Blum
* @see org.apache.geode.cache.client.ClientCache
* @see org.springframework.boot.SpringBootConfiguration
* @see org.springframework.boot.autoconfigure.EnableAutoConfiguration
* @see org.springframework.context.annotation.Bean
* @see org.springframework.context.annotation.Conditional
* @see org.springframework.context.annotation.Configuration
* @see org.springframework.context.annotation.Import
* @see org.springframework.data.gemfire.client.ClientCacheFactoryBean
* @see org.springframework.data.gemfire.config.annotation.ClientCacheConfigurer
@@ -46,7 +46,7 @@ import org.springframework.geode.config.annotation.ClusterAvailableConfiguration
* @see org.springframework.geode.config.annotation.ClusterAvailableConfiguration.AnyClusterAvailableCondition
* @since 1.0.0
*/
@Configuration
@SpringBootConfiguration
@Conditional(ClusterAvailableConfiguration.AnyClusterAvailableCondition.class)
@ConditionalOnBean(ClientCacheFactoryBean.class)
@ConditionalOnMissingBean(name = "continuousQueryBeanPostProcessor",

View File

@@ -21,6 +21,7 @@ import java.util.function.Predicate;
import org.apache.geode.cache.GemFireCache;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.SpringBootConfiguration;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.condition.AnyNestedCondition;
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
@@ -51,6 +52,7 @@ import org.springframework.lang.Nullable;
* @author John Blum
* @see org.apache.geode.cache.GemFireCache
* @see org.apache.geode.cache.Region
* @see org.springframework.boot.SpringBootConfiguration
* @see org.springframework.boot.autoconfigure.EnableAutoConfiguration
* @see org.springframework.boot.autoconfigure.condition.AnyNestedCondition
* @see org.springframework.boot.autoconfigure.condition.ConditionalOnBean
@@ -59,7 +61,6 @@ import org.springframework.lang.Nullable;
* @see org.springframework.context.annotation.Bean
* @see org.springframework.context.annotation.Condition
* @see org.springframework.context.annotation.Conditional
* @see org.springframework.context.annotation.Configuration
* @see org.springframework.core.env.ConfigurableEnvironment
* @see org.springframework.core.env.Environment
* @see org.springframework.data.gemfire.CacheFactoryBean
@@ -69,7 +70,7 @@ import org.springframework.lang.Nullable;
* @see org.springframework.geode.data.support.LifecycleAwareCacheDataImporterExporter
* @since 1.3.0
*/
@Configuration
@SpringBootConfiguration
@ConditionalOnBean(GemFireCache.class)
@ConditionalOnClass({ CacheFactoryBean.class, GemFireCache.class })
@SuppressWarnings("unused")

View File

@@ -22,11 +22,11 @@ import java.util.stream.Collectors;
import org.apache.geode.cache.GemFireCache;
import org.springframework.boot.SpringBootConfiguration;
import org.springframework.boot.autoconfigure.AutoConfigureBefore;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.core.Ordered;
import org.springframework.core.annotation.Order;
import org.springframework.core.env.ConfigurableEnvironment;
@@ -51,9 +51,9 @@ import org.slf4j.LoggerFactory;
* @author John Blum
* @see java.util.Properties
* @see org.apache.geode.cache.GemFireCache
* @see org.springframework.boot.SpringBootConfiguration
* @see org.springframework.boot.autoconfigure.EnableAutoConfiguration
* @see org.springframework.context.annotation.Bean
* @see org.springframework.context.annotation.Configuration
* @see org.springframework.core.Ordered
* @see org.springframework.core.annotation.Order
* @see org.springframework.core.env.ConfigurableEnvironment
@@ -66,7 +66,7 @@ import org.slf4j.LoggerFactory;
* @see <a href="https://geode.apache.org/docs/guide/112/reference/topics/gemfire_properties.html">Geode Properties</a>
* @since 1.3.0
*/
@Configuration
@SpringBootConfiguration
@ConditionalOnClass({ GemFireCache.class, CacheFactoryBean.class })
@AutoConfigureBefore({ ClientCacheAutoConfiguration.class })
@SuppressWarnings("unused")

View File

@@ -17,11 +17,11 @@ package org.springframework.geode.boot.autoconfigure;
import org.apache.geode.cache.GemFireCache;
import org.springframework.boot.SpringBootConfiguration;
import org.springframework.boot.autoconfigure.AutoConfigureAfter;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Import;
import org.springframework.data.gemfire.function.config.EnableGemfireFunctions;
import org.springframework.data.gemfire.function.execution.GemfireFunctionOperations;
@@ -33,8 +33,8 @@ import org.springframework.geode.function.config.GemFireFunctionExecutionAutoCon
*
* @author John Blum
* @see org.apache.geode.cache.GemFireCache
* @see org.springframework.boot.SpringBootConfiguration
* @see org.springframework.boot.autoconfigure.EnableAutoConfiguration
* @see org.springframework.context.annotation.Configuration
* @see org.springframework.context.annotation.Import
* @see org.springframework.data.gemfire.function.config.EnableGemfireFunctions
* @see org.springframework.data.gemfire.function.config.EnableGemfireFunctionExecutions
@@ -43,7 +43,7 @@ import org.springframework.geode.function.config.GemFireFunctionExecutionAutoCon
* @see org.springframework.geode.boot.autoconfigure.ClientCacheAutoConfiguration
* @since 1.0.0
*/
@Configuration
@SpringBootConfiguration
@AutoConfigureAfter(ClientCacheAutoConfiguration.class)
@ConditionalOnBean(GemFireCache.class)
@ConditionalOnClass({ GemfireFunctionOperations.class, GemFireCache.class })

View File

@@ -17,12 +17,12 @@ package org.springframework.geode.boot.autoconfigure;
import org.apache.geode.cache.GemFireCache;
import org.springframework.boot.SpringBootConfiguration;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.context.annotation.Configuration;
import org.springframework.core.env.Environment;
import org.springframework.data.gemfire.CacheFactoryBean;
import org.springframework.geode.boot.autoconfigure.configuration.GemFireProperties;
@@ -34,16 +34,16 @@ import org.springframework.geode.boot.autoconfigure.configuration.GemFirePropert
*
* @author John Blum
* @see org.apache.geode.cache.GemFireCache
* @see org.springframework.boot.SpringBootConfiguration
* @see org.springframework.boot.autoconfigure.EnableAutoConfiguration
* @see org.springframework.boot.context.properties.ConfigurationProperties
* @see org.springframework.boot.context.properties.EnableConfigurationProperties
* @see org.springframework.context.annotation.Configuration
* @see org.springframework.core.env.Environment
* @see org.springframework.data.gemfire.CacheFactoryBean
* @see org.springframework.geode.boot.autoconfigure.configuration.GemFireProperties
* @since 1.0.0
*/
@Configuration
@SpringBootConfiguration
@ConditionalOnBean(GemFireCache.class)
@ConditionalOnClass({ GemFireCache.class, CacheFactoryBean.class })
@EnableConfigurationProperties({ GemFireProperties.class })

View File

@@ -17,11 +17,11 @@ package org.springframework.geode.boot.autoconfigure;
import org.apache.geode.cache.GemFireCache;
import org.springframework.boot.SpringBootConfiguration;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.context.annotation.Configuration;
import org.springframework.data.gemfire.CacheFactoryBean;
import org.springframework.data.gemfire.config.annotation.EnableLogging;
@@ -29,16 +29,16 @@ import org.springframework.data.gemfire.config.annotation.EnableLogging;
* Spring Boot {@link EnableAutoConfiguration auto-Configuration} for Apache Geode logging.
*
* @author John Blum
* @see org.springframework.boot.SpringBootConfiguration
* @see org.springframework.boot.autoconfigure.EnableAutoConfiguration
* @see org.springframework.boot.autoconfigure.condition.ConditionalOnBean
* @see org.springframework.boot.autoconfigure.condition.ConditionalOnClass
* @see org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean
* @see org.springframework.context.annotation.Configuration
* @see org.springframework.data.gemfire.CacheFactoryBean
* @see org.springframework.data.gemfire.config.annotation.EnableLogging
* @since 1.1.0
*/
@Configuration
@SpringBootConfiguration
@ConditionalOnBean(GemFireCache.class)
@ConditionalOnClass(CacheFactoryBean.class)
@ConditionalOnMissingBean(name = {

View File

@@ -19,10 +19,10 @@ import org.apache.geode.cache.Cache;
import org.apache.geode.cache.GemFireCache;
import org.apache.geode.cache.client.ClientCache;
import org.springframework.boot.SpringBootConfiguration;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.context.annotation.Configuration;
import org.springframework.data.gemfire.config.annotation.EnablePdx;
/**
@@ -33,12 +33,12 @@ import org.springframework.data.gemfire.config.annotation.EnablePdx;
* @see org.apache.geode.cache.Cache
* @see org.apache.geode.cache.GemFireCache
* @see org.apache.geode.cache.client.ClientCache
* @see org.springframework.boot.SpringBootConfiguration
* @see org.springframework.boot.autoconfigure.EnableAutoConfiguration
* @see org.springframework.context.annotation.Configuration
* @see org.springframework.data.gemfire.config.annotation.EnablePdx
* @since 1.0.0
*/
@Configuration
@SpringBootConfiguration
@ConditionalOnBean(GemFireCache.class)
@ConditionalOnMissingBean(
name = { "clientCachePdxConfigurer", "peerCachePdxConfigurer" },

View File

@@ -15,6 +15,7 @@
*/
package org.springframework.geode.boot.autoconfigure;
import org.springframework.boot.SpringBootConfiguration;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
@@ -30,8 +31,8 @@ import org.springframework.geode.config.annotation.EnableSecurityManager;
*
* @author John Blum
* @see org.apache.geode.security.SecurityManager
* @see org.springframework.boot.SpringBootConfiguration
* @see org.springframework.boot.autoconfigure.EnableAutoConfiguration
* @see org.springframework.context.annotation.Configuration
* @see org.springframework.context.annotation.Import
* @see org.springframework.data.gemfire.CacheFactoryBean
* @see org.springframework.data.gemfire.client.ClientCacheFactoryBean
@@ -40,7 +41,7 @@ import org.springframework.geode.config.annotation.EnableSecurityManager;
* @see org.springframework.geode.config.annotation.EnableSecurityManager
* @since 1.0.0
*/
@Configuration
@SpringBootConfiguration
@ConditionalOnBean(org.apache.geode.security.SecurityManager.class)
@ConditionalOnMissingBean({
ClientCacheFactoryBean.class,

View File

@@ -39,6 +39,7 @@ import org.springframework.beans.factory.config.ConstructorArgumentValues;
import org.springframework.beans.factory.config.RuntimeBeanReference;
import org.springframework.beans.factory.support.BeanDefinitionBuilder;
import org.springframework.beans.factory.support.BeanDefinitionRegistry;
import org.springframework.boot.SpringBootConfiguration;
import org.springframework.boot.autoconfigure.AutoConfigureAfter;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
@@ -78,20 +79,20 @@ import org.springframework.util.StringUtils;
* @see org.springframework.beans.factory.config.ConfigurableBeanFactory
* @see org.springframework.beans.factory.support.BeanDefinitionBuilder
* @see org.springframework.beans.factory.support.BeanDefinitionRegistry
* @see org.springframework.boot.SpringBootConfiguration
* @see org.springframework.boot.autoconfigure.AutoConfigureAfter
* @see org.springframework.boot.autoconfigure.condition.ConditionalOnBean
* @see org.springframework.boot.autoconfigure.condition.ConditionalOnClass
* @see org.springframework.context.ApplicationContext
* @see org.springframework.context.ConfigurableApplicationContext
* @see org.springframework.context.annotation.Bean
* @see org.springframework.context.annotation.Configuration
* @see org.springframework.context.event.EventListener
* @see org.springframework.data.gemfire.GemfireTemplate
* @see org.springframework.data.gemfire.ResolvableRegionFactoryBean
* @see org.springframework.geode.config.annotation.support.TypelessAnnotationConfigSupport
* @since 1.0.0
*/
@Configuration
@SpringBootConfiguration
@AutoConfigureAfter(ClientCacheAutoConfiguration.class)
@ConditionalOnBean(GemFireCache.class)
@ConditionalOnClass(GemfireTemplate.class)

View File

@@ -19,13 +19,13 @@ import org.apache.geode.cache.Cache;
import org.apache.geode.cache.GemFireCache;
import org.apache.geode.cache.client.ClientCache;
import org.springframework.boot.SpringBootConfiguration;
import org.springframework.boot.autoconfigure.AutoConfigureAfter;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Import;
import org.springframework.data.gemfire.repository.GemfireRepository;
import org.springframework.data.gemfire.repository.config.EnableGemfireRepositories;
@@ -46,8 +46,8 @@ import org.springframework.data.gemfire.repository.support.GemfireRepositoryFact
* @see org.apache.geode.cache.Cache
* @see org.apache.geode.cache.GemFireCache
* @see org.apache.geode.cache.client.ClientCache
* @see org.springframework.boot.SpringBootConfiguration
* @see org.springframework.boot.autoconfigure.EnableAutoConfiguration
* @see org.springframework.context.annotation.Configuration
* @see org.springframework.context.annotation.Import
* @see org.springframework.data.gemfire.repository.GemfireRepository
* @see org.springframework.data.gemfire.repository.config.EnableGemfireRepositories
@@ -57,7 +57,7 @@ import org.springframework.data.gemfire.repository.support.GemfireRepositoryFact
* @see org.springframework.geode.boot.autoconfigure.GemFireRepositoriesAutoConfigurationRegistrar
* @since 1.0.0
*/
@Configuration
@SpringBootConfiguration
@AutoConfigureAfter(ClientCacheAutoConfiguration.class)
@ConditionalOnBean(GemFireCache.class)
@ConditionalOnClass(GemfireRepository.class)

View File

@@ -23,6 +23,7 @@ import java.util.Set;
import org.apache.geode.cache.GemFireCache;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.SpringBootConfiguration;
import org.springframework.boot.autoconfigure.AutoConfigureAfter;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
@@ -33,7 +34,6 @@ import org.springframework.boot.env.EnvironmentPostProcessor;
import org.springframework.context.annotation.Condition;
import org.springframework.context.annotation.ConditionContext;
import org.springframework.context.annotation.Conditional;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Import;
import org.springframework.core.env.ConfigurableEnvironment;
import org.springframework.core.env.PropertiesPropertySource;
@@ -54,6 +54,7 @@ import org.springframework.util.StringUtils;
* @see java.util.Properties
* @see org.apache.geode.cache.GemFireCache
* @see org.springframework.boot.SpringApplication
* @see org.springframework.boot.SpringBootConfiguration
* @see org.springframework.boot.autoconfigure.AutoConfigureAfter
* @see org.springframework.boot.autoconfigure.EnableAutoConfiguration
* @see org.springframework.boot.autoconfigure.condition.ConditionalOnBean
@@ -63,7 +64,6 @@ import org.springframework.util.StringUtils;
* @see org.springframework.context.annotation.Condition
* @see org.springframework.context.annotation.ConditionContext
* @see org.springframework.context.annotation.Conditional
* @see org.springframework.context.annotation.Configuration
* @see org.springframework.context.annotation.Import
* @see org.springframework.core.env.ConfigurableEnvironment
* @see org.springframework.core.env.PropertiesPropertySource
@@ -76,7 +76,7 @@ import org.springframework.util.StringUtils;
* @see org.springframework.session.web.http.SessionRepositoryFilter
* @since 1.0.0
*/
@Configuration
@SpringBootConfiguration
@AutoConfigureAfter(ClientCacheAutoConfiguration.class)
@Conditional(SpringSessionAutoConfiguration.SpringSessionStoreTypeCondition.class)
@ConditionalOnBean(GemFireCache.class)

View File

@@ -17,12 +17,12 @@ package org.springframework.geode.boot.autoconfigure;
import org.apache.geode.cache.GemFireCache;
import org.springframework.boot.SpringBootConfiguration;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.context.annotation.Configuration;
import org.springframework.core.env.Environment;
import org.springframework.data.gemfire.CacheFactoryBean;
import org.springframework.geode.boot.autoconfigure.configuration.SpringSessionProperties;
@@ -36,16 +36,16 @@ import org.springframework.session.data.gemfire.config.annotation.web.http.GemFi
*
* @author John Blum
* @see org.apache.geode.cache.GemFireCache
* @see org.springframework.boot.SpringBootConfiguration
* @see org.springframework.boot.autoconfigure.EnableAutoConfiguration
* @see org.springframework.boot.context.properties.ConfigurationProperties
* @see org.springframework.boot.context.properties.EnableConfigurationProperties
* @see org.springframework.context.annotation.Configuration
* @see org.springframework.core.env.Environment
* @see org.springframework.geode.boot.autoconfigure.configuration.SpringSessionProperties
* @see org.springframework.session.SessionRepository
* @since 1.0.0
*/
@Configuration
@SpringBootConfiguration
@ConditionalOnBean({ GemFireCache.class, SessionRepository.class })
@ConditionalOnClass({ GemFireCache.class, CacheFactoryBean.class, GemFireHttpSessionConfiguration.class })
@EnableConfigurationProperties({ SpringSessionProperties.class })

View File

@@ -28,6 +28,7 @@ import java.util.Properties;
import org.apache.geode.cache.GemFireCache;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.SpringBootConfiguration;
import org.springframework.boot.autoconfigure.AutoConfigureBefore;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.condition.AllNestedConditions;
@@ -38,7 +39,6 @@ import org.springframework.boot.env.EnvironmentPostProcessor;
import org.springframework.context.annotation.Condition;
import org.springframework.context.annotation.ConditionContext;
import org.springframework.context.annotation.Conditional;
import org.springframework.context.annotation.Configuration;
import org.springframework.core.env.ConfigurableEnvironment;
import org.springframework.core.env.Environment;
import org.springframework.core.env.PropertiesPropertySource;
@@ -66,6 +66,7 @@ import org.slf4j.LoggerFactory;
* @see java.util.Properties
* @see org.apache.geode.cache.GemFireCache
* @see org.springframework.boot.SpringApplication
* @see org.springframework.boot.SpringBootConfiguration
* @see org.springframework.boot.autoconfigure.AutoConfigureBefore
* @see org.springframework.boot.autoconfigure.EnableAutoConfiguration
* @see org.springframework.boot.autoconfigure.condition.ConditionalOnClass
@@ -74,7 +75,6 @@ import org.slf4j.LoggerFactory;
* @see org.springframework.context.annotation.Condition
* @see org.springframework.context.annotation.ConditionContext
* @see org.springframework.context.annotation.Conditional
* @see org.springframework.context.annotation.Configuration
* @see org.springframework.core.env.ConfigurableEnvironment
* @see org.springframework.core.env.Environment
* @see org.springframework.core.env.PropertiesPropertySource
@@ -87,7 +87,7 @@ import org.slf4j.LoggerFactory;
* @see org.springframework.geode.boot.autoconfigure.ClientCacheAutoConfiguration
* @since 1.0.0
*/
@Configuration
@SpringBootConfiguration
@AutoConfigureBefore(ClientCacheAutoConfiguration.class)
@Conditional(SslAutoConfiguration.EnableSslCondition.class)
@ConditionalOnClass({ CacheFactoryBean.class, GemFireCache.class })