From 6253000ee5f82930fdeaa5dde8757f2a9ff59a16 Mon Sep 17 00:00:00 2001 From: John Blum Date: Mon, 18 May 2020 00:41:24 -0700 Subject: [PATCH] Annotate the Look-Aside Caching GeodeConfiguration class with the @EnableClusterAware annotation. Remove the explicit 'clientRegionShortcut' configuration from the @EnableCachingDefinedRegions annotation specifying a client 'LOCAL' Region. --- .../caching/lookaside/config/GeodeConfiguration.java | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/spring-geode-samples/caching/look-aside/src/main/java/example/app/caching/lookaside/config/GeodeConfiguration.java b/spring-geode-samples/caching/look-aside/src/main/java/example/app/caching/lookaside/config/GeodeConfiguration.java index 2b37e442..7a93bd59 100644 --- a/spring-geode-samples/caching/look-aside/src/main/java/example/app/caching/lookaside/config/GeodeConfiguration.java +++ b/spring-geode-samples/caching/look-aside/src/main/java/example/app/caching/lookaside/config/GeodeConfiguration.java @@ -15,26 +15,23 @@ */ package example.app.caching.lookaside.config; -import org.apache.geode.cache.client.ClientRegionShortcut; - import org.springframework.context.annotation.Configuration; import org.springframework.data.gemfire.config.annotation.EnableCachingDefinedRegions; -import org.springframework.data.gemfire.config.annotation.EnableLogging; +import org.springframework.geode.config.annotation.EnableClusterAware; /** * Spring {@link Configuration} class used to configure Apache Geode. * * @author John Blum - * @see org.apache.geode.cache.client.ClientRegionShortcut * @see org.springframework.context.annotation.Configuration * @see org.springframework.data.gemfire.config.annotation.EnableCachingDefinedRegions - * @see org.springframework.data.gemfire.config.annotation.EnableClusterConfiguration + * @see org.springframework.geode.config.annotation.EnableClusterAware * @since 1.0.0 */ @SuppressWarnings("unused") // tag::class[] @Configuration -@EnableLogging(logLevel = "error") -@EnableCachingDefinedRegions(clientRegionShortcut = ClientRegionShortcut.LOCAL) +@EnableClusterAware +@EnableCachingDefinedRegions public class GeodeConfiguration { } // end::class[]