Rename all auto-configuration classes by removing the 'Geode' name prefix.
This commit is contained in:
@@ -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.autoconfigure.AutoConfigureAfter;
|
||||
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
|
||||
import org.springframework.boot.autoconfigure.cache.CacheManagerCustomizers;
|
||||
import org.springframework.boot.autoconfigure.cache.CacheProperties;
|
||||
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
|
||||
@@ -36,24 +37,28 @@ import org.springframework.data.gemfire.cache.GemfireCacheManager;
|
||||
import org.springframework.data.gemfire.cache.config.EnableGemfireCaching;
|
||||
|
||||
/**
|
||||
* Cache auto-configuration for Spring's Cache Abstraction, using Apache Geode as the caching provider.
|
||||
* Spring Boot {@link EnableAutoConfiguration auto-configuration} for Spring's Cache Abstraction
|
||||
* using Apache Geode or Pivotal GemFire as the caching provider.
|
||||
*
|
||||
* @author John Blum
|
||||
* @see org.apache.geode.cache.Cache
|
||||
* @see org.apache.geode.cache.GemFireCache
|
||||
* @see org.apache.geode.cache.client.ClientCache
|
||||
* @see org.springframework.boot.autoconfigure.cache.CacheManagerCustomizers
|
||||
* @see org.springframework.boot.autoconfigure.cache.CacheProperties
|
||||
* @see org.springframework.boot.data.geode.autoconfigure.ClientCacheAutoConfiguration
|
||||
* @see org.springframework.context.annotation.Configuration
|
||||
* @see org.springframework.cache.CacheManager
|
||||
* @see org.springframework.data.gemfire.cache.GemfireCacheManager
|
||||
* @since 1.5.0
|
||||
* @see org.springframework.data.gemfire.cache.config.EnableGemfireCaching
|
||||
* @since 1.0.0
|
||||
*/
|
||||
@Configuration
|
||||
@ConditionalOnBean(GemFireCache.class)
|
||||
@ConditionalOnClass({ GemfireCacheManager.class, GemFireCache.class })
|
||||
@ConditionalOnMissingBean(CacheManager.class)
|
||||
@AutoConfigureAfter(GeodeClientCacheAutoConfiguration.class)
|
||||
@AutoConfigureAfter(ClientCacheAutoConfiguration.class)
|
||||
@EnableGemfireCaching
|
||||
@SuppressWarnings("all")
|
||||
class GeodeCachingProviderAutoConfiguration {
|
||||
class CachingProviderAutoConfiguration {
|
||||
|
||||
private final CacheManagerCustomizers cacheManagerCustomizers;
|
||||
|
||||
@@ -62,7 +67,7 @@ class GeodeCachingProviderAutoConfiguration {
|
||||
@Autowired
|
||||
private GemfireCacheManager cacheManager;
|
||||
|
||||
GeodeCachingProviderAutoConfiguration(
|
||||
CachingProviderAutoConfiguration(
|
||||
@Autowired(required = false) CacheProperties cacheProperties,
|
||||
@Autowired(required = false) CacheManagerCustomizers cacheManagerCustomizers) {
|
||||
|
||||
@@ -31,12 +31,11 @@ import org.springframework.data.gemfire.config.annotation.EnablePdx;
|
||||
* instance constructed, configured and initialized with Spring Data for Apache Geode.
|
||||
*
|
||||
* Additionally, this configuration automatically enables Apache Geode PDX serialization to serialize data sent
|
||||
* between the client and server(s) in the cluster.
|
||||
* between the client and server(s) in the cluster in the client/server topology.
|
||||
*
|
||||
* @author John Blum
|
||||
* @see org.apache.geode.cache.Cache
|
||||
* @see org.apache.geode.cache.GemFireCache
|
||||
* @see org.apache.geode.cache.client.ClientCache
|
||||
* @see org.springframework.boot.autoconfigure.EnableAutoConfiguration
|
||||
* @see org.springframework.context.annotation.Configuration
|
||||
* @see org.springframework.data.gemfire.client.ClientCacheFactoryBean
|
||||
* @see org.springframework.data.gemfire.config.annotation.ClientCacheApplication
|
||||
@@ -49,6 +48,6 @@ import org.springframework.data.gemfire.config.annotation.EnablePdx;
|
||||
@ClientCacheApplication
|
||||
@EnablePdx
|
||||
@SuppressWarnings("all")
|
||||
public class GeodeClientCacheAutoConfiguration {
|
||||
public class ClientCacheAutoConfiguration {
|
||||
|
||||
}
|
||||
@@ -30,11 +30,13 @@ import org.springframework.data.gemfire.config.annotation.EnableContinuousQuerie
|
||||
|
||||
/**
|
||||
* Spring Boot {@link EnableAutoConfiguration auto-configuration} enabling Apache Geode's Continuous Query (CQ)
|
||||
* functionality in an Spring Boot, Apache Geode {@link ClientCache} application.
|
||||
* functionality in a {@link ClientCache} application.
|
||||
*
|
||||
* @author John Blum
|
||||
* @see org.apache.geode.cache.Cache
|
||||
* @see org.apache.geode.cache.GemFireCache
|
||||
* @see org.apache.geode.cache.client.ClientCache
|
||||
* @see org.springframework.boot.autoconfigure.EnableAutoConfiguration
|
||||
* @see org.springframework.boot.data.geode.autoconfigure.ClientCacheAutoConfiguration
|
||||
* @see org.springframework.context.annotation.Configuration
|
||||
* @see org.springframework.data.gemfire.client.ClientCacheFactoryBean
|
||||
* @see org.springframework.data.gemfire.config.annotation.EnableContinuousQueries
|
||||
@@ -44,8 +46,8 @@ import org.springframework.data.gemfire.config.annotation.EnableContinuousQuerie
|
||||
@ConditionalOnBean(GemFireCache.class)
|
||||
@ConditionalOnClass({ ClientCacheFactoryBean.class, ClientCache.class })
|
||||
@ConditionalOnMissingBean(name = "continuousQueryBeanPostProcessor", value = Cache.class)
|
||||
@AutoConfigureAfter(GeodeClientCacheAutoConfiguration.class)
|
||||
@AutoConfigureAfter(ClientCacheAutoConfiguration.class)
|
||||
@EnableContinuousQueries
|
||||
public class GeodeContinuousQueryAutoConfiguration {
|
||||
public class ContinuousQueryAutoConfiguration {
|
||||
|
||||
}
|
||||
@@ -17,7 +17,6 @@
|
||||
package org.springframework.boot.data.geode.autoconfigure;
|
||||
|
||||
import org.apache.geode.cache.GemFireCache;
|
||||
import org.apache.geode.cache.client.ClientCache;
|
||||
import org.springframework.boot.autoconfigure.AutoConfigureAfter;
|
||||
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
|
||||
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
|
||||
@@ -28,21 +27,22 @@ import org.springframework.data.gemfire.function.execution.GemfireFunctionOperat
|
||||
|
||||
/**
|
||||
* Spring Boot {@link EnableAutoConfiguration auto-configuration} enabling Apache Geode's Function Execution
|
||||
* functionality in a Spring Boot, Apache Geode {@link ClientCache} application.
|
||||
* functionality in a {@link GemFireCache} application.
|
||||
*
|
||||
* @author John Blum
|
||||
* @see org.apache.geode.cache.GemFireCache
|
||||
* @see org.springframework.boot.autoconfigure.EnableAutoConfiguration
|
||||
* @see org.springframework.boot.data.geode.autoconfigure.ClientCacheAutoConfiguration
|
||||
* @see org.springframework.context.annotation.Configuration
|
||||
* @see org.springframework.data.gemfire.function.config.EnableGemfireFunctionExecutions
|
||||
* @see org.springframework.data.gemfire.function.execution.GemfireFunctionOperations
|
||||
* @since 1.0.0
|
||||
*/
|
||||
@Configuration
|
||||
@ConditionalOnBean(GemFireCache.class)
|
||||
@ConditionalOnClass({ GemfireFunctionOperations.class, GemFireCache.class })
|
||||
@AutoConfigureAfter(GeodeClientCacheAutoConfiguration.class)
|
||||
@AutoConfigureAfter(ClientCacheAutoConfiguration.class)
|
||||
@EnableGemfireFunctionExecutions
|
||||
@SuppressWarnings("unused")
|
||||
public class GeodeFunctionExecutionAutoConfiguration {
|
||||
public class FunctionExecutionAutoConfiguration {
|
||||
|
||||
}
|
||||
@@ -28,38 +28,41 @@ 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;
|
||||
import org.springframework.data.gemfire.repository.config.GemfireRepositoryConfigurationExtension;
|
||||
import org.springframework.data.gemfire.repository.support.GemfireRepositoryFactoryBean;
|
||||
|
||||
/**
|
||||
* Spring Boot {@link EnableAutoConfiguration auto-configuration} for Spring Data's Geode Repositories.
|
||||
* Spring Boot {@link EnableAutoConfiguration auto-configuration} for Spring Data Geode
|
||||
* and Spring Data GemFire Repositories.
|
||||
*
|
||||
* Activates when there is a bean of type {@link Cache} or {@link ClientCache} configured in the Spring context,
|
||||
* the Spring Data Geode {@link org.springframework.data.gemfire.repository.GemfireRepository} type is on the classpath,
|
||||
* and there is no other existing {@link org.springframework.data.gemfire.repository.GemfireRepository} configured.
|
||||
* the Spring Data Geode {@link GemfireRepository} type is on the classpath, and no other existing
|
||||
* {@link GemfireRepository GemfireRepositories} are configured.
|
||||
*
|
||||
* Once in effect, the auto-configuration is the equivalent of enabling Geode Repositories using the
|
||||
* {@link org.springframework.data.gemfire.repository.config.EnableGemfireRepositories} annotation.
|
||||
* {@link EnableGemfireRepositories} annotation.
|
||||
*
|
||||
* @author John Blum
|
||||
* @since 1.0.0
|
||||
* @see org.apache.geode.cache.Cache
|
||||
* @see org.apache.geode.cache.GemFireCache
|
||||
* @see org.apache.geode.cache.client.ClientCache
|
||||
* @see org.springframework.boot.data.geode.autoconfigure.GeodeRepositoriesAutoConfigurationRegistrar
|
||||
* @see org.springframework.boot.data.geode.autoconfigure.RepositoriesAutoConfigurationRegistrar
|
||||
* @see org.springframework.context.annotation.Configuration
|
||||
* @see org.springframework.data.gemfire.repository.GemfireRepository
|
||||
* @see org.springframework.data.gemfire.repository.config.EnableGemfireRepositories
|
||||
* @see org.springframework.data.gemfire.repository.config.GemfireRepositoryConfigurationExtension
|
||||
* @see org.springframework.data.gemfire.repository.support.GemfireRepositoryFactoryBean
|
||||
* @since 1.0.0
|
||||
*/
|
||||
@Configuration
|
||||
@ConditionalOnBean({ GemFireCache.class })
|
||||
@ConditionalOnBean(GemFireCache.class)
|
||||
@ConditionalOnClass(GemfireRepository.class)
|
||||
@ConditionalOnMissingBean({ GemfireRepositoryConfigurationExtension.class, GemfireRepositoryFactoryBean.class })
|
||||
@ConditionalOnProperty(prefix = "spring.data.gemfire.repositories",
|
||||
name = "enabled", havingValue = "true", matchIfMissing = true)
|
||||
@AutoConfigureAfter(GeodeClientCacheAutoConfiguration.class)
|
||||
@Import(GeodeRepositoriesAutoConfigurationRegistrar.class)
|
||||
public class GeodeRepositoriesAutoConfiguration {
|
||||
@AutoConfigureAfter(ClientCacheAutoConfiguration.class)
|
||||
@Import(RepositoriesAutoConfigurationRegistrar.class)
|
||||
public class RepositoriesAutoConfiguration {
|
||||
|
||||
}
|
||||
@@ -29,13 +29,13 @@ import org.springframework.data.repository.config.RepositoryConfigurationExtensi
|
||||
*
|
||||
* @author John Blum
|
||||
* @see org.springframework.boot.autoconfigure.data.AbstractRepositoryConfigurationSourceSupport
|
||||
* @see org.springframework.boot.data.geode.autoconfigure.GeodeRepositoriesAutoConfiguration
|
||||
* @see org.springframework.boot.data.geode.autoconfigure.GeodeRepositoriesAutoConfigurationRegistrar.EnableGeodeRepositoriesConfiguration
|
||||
* @see org.springframework.boot.data.geode.autoconfigure.RepositoriesAutoConfiguration
|
||||
* @see org.springframework.boot.data.geode.autoconfigure.RepositoriesAutoConfigurationRegistrar.EnableGeodeRepositoriesConfiguration
|
||||
* @see org.springframework.data.gemfire.repository.config.EnableGemfireRepositories
|
||||
* @see org.springframework.data.gemfire.repository.config.GemfireRepositoryConfigurationExtension
|
||||
* @since 1.0.0
|
||||
*/
|
||||
public class GeodeRepositoriesAutoConfigurationRegistrar extends AbstractRepositoryConfigurationSourceSupport {
|
||||
public class RepositoriesAutoConfigurationRegistrar extends AbstractRepositoryConfigurationSourceSupport {
|
||||
|
||||
@Override
|
||||
protected Class<? extends Annotation> getAnnotation() {
|
||||
@@ -1,7 +1,7 @@
|
||||
# Auto Configuration
|
||||
org.springframework.boot.autoconfigure.EnableAutoConfiguration=\
|
||||
org.springframework.boot.data.geode.autoconfigure.GeodeClientCacheAutoConfiguration,\
|
||||
org.springframework.boot.data.geode.autoconfigure.GeodeCachingProviderAutoConfiguration,\
|
||||
org.springframework.boot.data.geode.autoconfigure.GeodeContinuousQueryAutoConfiguration,\
|
||||
org.springframework.boot.data.geode.autoconfigure.GeodeFunctionExecutionAutoConfiguration,\
|
||||
org.springframework.boot.data.geode.autoconfigure.GeodeRepositoriesAutoConfiguration
|
||||
org.springframework.boot.data.geode.autoconfigure.ClientCacheAutoConfiguration,\
|
||||
org.springframework.boot.data.geode.autoconfigure.CachingProviderAutoConfiguration,\
|
||||
org.springframework.boot.data.geode.autoconfigure.ContinuousQueryAutoConfiguration,\
|
||||
org.springframework.boot.data.geode.autoconfigure.FunctionExecutionAutoConfiguration,\
|
||||
org.springframework.boot.data.geode.autoconfigure.RepositoriesAutoConfiguration
|
||||
|
||||
Reference in New Issue
Block a user