From f1a959350aef285bca9c233655b005a8f736958e Mon Sep 17 00:00:00 2001 From: John Blum Date: Wed, 3 Sep 2014 18:18:08 -0700 Subject: [PATCH] Post-merge (cherry-pick) cleanup, fixing test failures and merge change conflicts. --- .../data/gemfire/support/JSONRegionAdvice.java | 8 ++++++-- .../data/gemfire/config/ClientRegionNamespaceTest.java | 3 +-- .../gemfire/config/TemplateClientRegionNamespaceTest.java | 1 - .../gemfire/config/TemplateRegionsNamespaceTests.java | 1 - src/test/resources/autoregionlookup-cache.xml | 2 +- .../config/TemplateRegionsNamespaceTests-context.xml | 4 ++-- .../org/springframework/data/gemfire/config/client-ns.xml | 1 - 7 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/main/java/org/springframework/data/gemfire/support/JSONRegionAdvice.java b/src/main/java/org/springframework/data/gemfire/support/JSONRegionAdvice.java index 57511226..cb190bb1 100644 --- a/src/main/java/org/springframework/data/gemfire/support/JSONRegionAdvice.java +++ b/src/main/java/org/springframework/data/gemfire/support/JSONRegionAdvice.java @@ -25,10 +25,10 @@ import org.apache.commons.logging.LogFactory; import org.aspectj.lang.ProceedingJoinPoint; import org.aspectj.lang.annotation.Around; import org.aspectj.lang.annotation.Aspect; -import org.codehaus.jackson.map.ObjectMapper; import org.springframework.data.gemfire.GemfireTemplate; import org.springframework.util.CollectionUtils; +import com.fasterxml.jackson.databind.ObjectMapper; import com.gemstone.gemfire.cache.Region; import com.gemstone.gemfire.cache.query.SelectResults; import com.gemstone.gemfire.cache.query.internal.ResultsBag; @@ -41,11 +41,14 @@ import com.gemstone.gemfire.pdx.PdxInstance; */ @Aspect public class JSONRegionAdvice { + private static Log log = LogFactory.getLog(JSONRegionAdvice.class); - private List includedRegions; + private boolean convertReturnedCollections = true; private boolean prettyPrint = false; + private List includedRegions; + /** * Sets names of regions to be included for JSON conversion. By default, all regions will be included * @param regionNames a List of region names to include @@ -276,4 +279,5 @@ public class JSONRegionAdvice { } } + } diff --git a/src/test/java/org/springframework/data/gemfire/config/ClientRegionNamespaceTest.java b/src/test/java/org/springframework/data/gemfire/config/ClientRegionNamespaceTest.java index 5625818b..0566053d 100644 --- a/src/test/java/org/springframework/data/gemfire/config/ClientRegionNamespaceTest.java +++ b/src/test/java/org/springframework/data/gemfire/config/ClientRegionNamespaceTest.java @@ -57,9 +57,8 @@ import com.gemstone.gemfire.cache.util.ObjectSizer; * @author David Turanski * @author John Blum */ -@ContextConfiguration(locations="/org/springframework/data/gemfire/config/client-ns.xml", - initializers=GemfireTestApplicationContextInitializer.class) @RunWith(SpringJUnit4ClassRunner.class) +@ContextConfiguration(locations="client-ns.xml", initializers=GemfireTestApplicationContextInitializer.class) @SuppressWarnings("unused") public class ClientRegionNamespaceTest { diff --git a/src/test/java/org/springframework/data/gemfire/config/TemplateClientRegionNamespaceTest.java b/src/test/java/org/springframework/data/gemfire/config/TemplateClientRegionNamespaceTest.java index aff35d60..6fe1c2c5 100644 --- a/src/test/java/org/springframework/data/gemfire/config/TemplateClientRegionNamespaceTest.java +++ b/src/test/java/org/springframework/data/gemfire/config/TemplateClientRegionNamespaceTest.java @@ -133,7 +133,6 @@ public class TemplateClientRegionNamespaceTest { assertNotNull("The Region must not be null!", region); assertNotNull(String.format("The Region (%1$s) must have 'RegionAttributes' defined!", region.getFullPath()), region.getAttributes()); - assertNull(region.getAttributes().getCompressor()); assertNull(region.getAttributes().getCustomEntryIdleTimeout()); assertNull(region.getAttributes().getCustomEntryTimeToLive()); assertNull(region.getAttributes().getDiskStoreName()); diff --git a/src/test/java/org/springframework/data/gemfire/config/TemplateRegionsNamespaceTests.java b/src/test/java/org/springframework/data/gemfire/config/TemplateRegionsNamespaceTests.java index 32e03d5d..17b47f0c 100644 --- a/src/test/java/org/springframework/data/gemfire/config/TemplateRegionsNamespaceTests.java +++ b/src/test/java/org/springframework/data/gemfire/config/TemplateRegionsNamespaceTests.java @@ -236,7 +236,6 @@ public class TemplateRegionsNamespaceTests { assertNotNull("The Region must not be null!", region); assertNotNull(String.format("The Region (%1$s) must have 'RegionAttributes' defined!", region.getFullPath()), region.getAttributes()); - assertNull(region.getAttributes().getCompressor()); assertNull(region.getAttributes().getCustomEntryIdleTimeout()); assertNull(region.getAttributes().getCustomEntryTimeToLive()); assertNull(region.getAttributes().getDiskStoreName()); diff --git a/src/test/resources/autoregionlookup-cache.xml b/src/test/resources/autoregionlookup-cache.xml index 45736335..5d843172 100644 --- a/src/test/resources/autoregionlookup-cache.xml +++ b/src/test/resources/autoregionlookup-cache.xml @@ -1,6 +1,6 @@ + "http://www.gemstone.com/dtd/cache7_0.dtd"> diff --git a/src/test/resources/org/springframework/data/gemfire/config/TemplateRegionsNamespaceTests-context.xml b/src/test/resources/org/springframework/data/gemfire/config/TemplateRegionsNamespaceTests-context.xml index fc8b6ec3..83fd9fc6 100644 --- a/src/test/resources/org/springframework/data/gemfire/config/TemplateRegionsNamespaceTests-context.xml +++ b/src/test/resources/org/springframework/data/gemfire/config/TemplateRegionsNamespaceTests-context.xml @@ -18,14 +18,14 @@ - + + parallel="false" dispatcher-threads="8"/> diff --git a/src/test/resources/org/springframework/data/gemfire/config/client-ns.xml b/src/test/resources/org/springframework/data/gemfire/config/client-ns.xml index 1e13a8f9..700f0a69 100644 --- a/src/test/resources/org/springframework/data/gemfire/config/client-ns.xml +++ b/src/test/resources/org/springframework/data/gemfire/config/client-ns.xml @@ -63,6 +63,5 @@ value-constraint="java.lang.String"/> -