diff --git a/build.gradle b/build.gradle
index 9a96e6d0..d35c11e7 100644
--- a/build.gradle
+++ b/build.gradle
@@ -14,7 +14,7 @@ group = 'org.springframework.data'
repositories {
maven { url "http://repo.springsource.org/libs-milestone" }
maven { url "http://repo.springsource.org/plugins-release"}
- maven { url "https://repo.springsource.org/ext-private-local"}
+ maven { url "http://dist.gemstone.com.s3.amazonaws.com/maven/release"}
}
diff --git a/docs/src/reference/docbook/introduction/new-features.xml b/docs/src/reference/docbook/introduction/new-features.xml
index 5232f5ff..064b5dc4 100644
--- a/docs/src/reference/docbook/introduction/new-features.xml
+++ b/docs/src/reference/docbook/introduction/new-features.xml
@@ -1,47 +1,76 @@
-
-New Features
+
+
+ New Features
-
-As of the 1.2.0 release, this project, formerly known as Spring GemFire, has been renamed to Spring Data GemFire to reflect that
-it is now a component of the Spring Data project.
-
-
-
-New in the 1.2.0 Release
-
-
-Full support for GemFire configuration via the gfe namespace. Now GemFire components may be configured completely without
-requiring a native cache.xml file.
-
-
-
-WAN Gateway support for both GemFire 6.6.x. See
-
-
-
-Spring Data Repository support with a dedicated namespace, gfe-data. See
-
-
-
-Namespace support for registering GemFire functions. See
-
-
-
-
-A top level <disk-store> element has been added to the gfe namespace to allow sharing of persist stores among regions,
-and other components that support persistent backup. See
-The <*-region> elements no longer allow a nested <disk-store>
-
-
-
-
-GemFire subregions are supported via nested <*-region> elements
-
-
-
- A <local-region> element has been added to configure a local region
-
-
-
-
-
\ No newline at end of file
+
+ As of the 1.2.0 release, this project, formerly known as Spring GemFire, has been renamed to Spring Data GemFire to reflect that it is now a component of the
+
+ Spring Data
+
+ project.
+
+
+
+ New in the 1.2.1 Release
+
+
+
+ WAN Gateway Support for GemFire 7.0
+
+
+
+
+
+ New in the 1.2.0 Release
+
+
+
+ Full support for GemFire configuration via the
+ gfe namespace. Now GemFire components may be
+ configured completely without requiring a native cache.xml
+ file.
+
+
+
+ WAN Gateway support for GemFire 6.6.x. See
+
+
+
+ Spring Data Repository support with a dedicated namespace,
+ gfe-data. See
+
+
+
+ Namespace support for registering GemFire functions. See
+
+
+
+ A top level <disk-store> element has
+ been added to the gfe namespace to allow sharing
+ of persist stores among regions, and other components that support
+ persistent backup. See
+ The <*-region> elements no longer
+ allow a nested <disk-store>
+
+
+
+ GemFire subregions are supported via nested
+ <*-region> elements
+
+
+
+ A <local-region> element has been added
+ to configure a local region
+
+
+
+
diff --git a/docs/src/reference/docbook/reference/gateway.xml b/docs/src/reference/docbook/reference/gateway.xml
index 4d5ee306..2d1b9ce8 100644
--- a/docs/src/reference/docbook/reference/gateway.xml
+++ b/docs/src/reference/docbook/reference/gateway.xml
@@ -1,5 +1,5 @@
-WAN gateways provide a way to synchronize GemFire distributed systems
across geographic distributed areas. As of Release 1.2.0, Spring Data
GemFire provides namespace support for configuring WAN gateways as
- illustrated in the following example:
+ illustrated in the following examples:
- <gfe:cache/>
+ WAN Configuration in GemFire 7.0
+
+ GemFire 7.0 introduces new APIs for WAN configuration. While the original APIs provided
+ in GemFire 6 are still supported, it is recommended that you use the new
+ APIs if you are using GemFire 7.0. The Spring Data GemFire namespace
+ supports either. In the example below, GatewaySenders are configured for a
+ partitioned region by adding child elements to the region (gateway-sender
+ and gateway-sender-ref). The GatewaySender may register
+ EventFilters and
+ TransportFilters. Also shown below is an example configuration of an
+ AsyncEventQueue which must also be wired into a region (not shown).
+
+
+ <gfe:partitioned-region id="region-inner-gateway-sender" >
+ <gfe:gateway-sender
+ remote-distributed-system-id="1">
+ <gfe:event-filter>
+ <bean class="org.springframework.data.gemfire.example.SomeEventFilter"/>
+ </gfe:event-filter>
+ <gfe:transport-filter>
+ <bean class="org.springframework.data.gemfire.example.SomeTransportFilter"/>
+ </gfe:transport-filter>
+ </gfe:gateway-sender>
+ <gfe:gateway-sender-ref bean="gateway-sender"/>
+</gfe:partitioned-region>
+
+<gfe:async-event-queue id="async-event-queue" batch-size="10" persistent="true" disk-store-ref="diskstore"
+ maximum-queue-memory="50">
+ <gfe:async-event-listener>
+ <bean class="org.springframework.data.gemfire.example.SomeAsyncEventListener"/>
+ </gfe:async-event-listener>
+</gfe:async-event-queue>
+
+
+<gfe:gateway-sender id="gateway-sender" remote-distributed-system-id="2">
+ <gfe:event-filter>
+ <ref bean="event-filter"/>
+ <bean class="org.springframework.data.gemfire.example.SomeEventFilter"/>
+ </gfe:event-filter>
+ <gfe:transport-filter>
+ <ref bean="transport-filter"/>
+ <bean class="org.springframework.data.gemfire.example.SomeTransportFilter"/>
+ </gfe:transport-filter>
+</gfe:gateway-sender>
+
+<bean id="event-filter" class="org.springframework.data.gemfire.example.AnotherEventFilter"/>
+<bean id="transport-filter" class="org.springframework.data.gemfire.example.AnotherTransportFilter"/>
+
+
+ On the other end of a GatewaySender is a corresponding
+ GatewayReceiver
+ to receive gateway events. The GatewayReceiver may also be configured with
+ EventFilters and TransportFilters.
+
+ <gfe:gateway-receiver id="gateway-receiver"
+ start-port="12345" end-port="23456" bind-address="192.168.0.1">
+ <gfe:transport-filter>
+ <bean class="org.springframework.data.gemfire.example.SomeTransportFilter"/>
+ </gfe:transport-filter>
+</gfe:gateway-receiver>
+Please refer to the GemFire product document for a detailed
+ explanation of all the configuration options.
+
+
+
+
+ WAN Configuration in GemFire 6.6
+
+ <gfe:cache/>
<gfe:replicated-region id="region-with-gateway" enable-gateway="true" hub-id="gateway-hub"/>
@@ -33,16 +101,19 @@
</gfe:gateway>
</gfe:gateway-hub>
- A region may synchronize all or part of its contents to a gateway hub
- used to access one or more remote systems. The region must set
- enable-gateway to true and specify the
- hub-id.
+ A region may synchronize all or part of its contents to a gateway
+ hub used to access one or more remote systems. The region must set
+ enable-gateway to true and specify
+ the hub-id.
-
- If just a hub-id is specified, Spring Data GemFire automatically
- assumes that the gateway should be enabled.
-
+
+
+ If just a hub-id is specified, Spring Data GemFire automatically
+ assumes that the gateway should be enabled.
+
+
- Please refer to the GemFire product document for a detailed
- explanation of all the configuration options.
+ Please refer to the GemFire product document for a detailed
+ explanation of all the configuration options.
+
diff --git a/gradle.properties b/gradle.properties
index 05a0c390..e39ab884 100644
--- a/gradle.properties
+++ b/gradle.properties
@@ -7,7 +7,7 @@ slf4jVersion = 1.6.4
# Common libraries
springVersion = 3.1.2.RELEASE
springDataCommonsVersion = 1.4.0.RELEASE
-gemfireVersion = 7.0.Beta-SNAPSHOT
+gemfireVersion = 7.0
gemfireVersion6x = 6.6.3
# Testing
diff --git a/src/main/java/org/springframework/data/gemfire/config/AbstractRegionParser.java b/src/main/java/org/springframework/data/gemfire/config/AbstractRegionParser.java
index 6fa61600..fe65f1b3 100644
--- a/src/main/java/org/springframework/data/gemfire/config/AbstractRegionParser.java
+++ b/src/main/java/org/springframework/data/gemfire/config/AbstractRegionParser.java
@@ -123,14 +123,14 @@ abstract class AbstractRegionParser extends AliasReplacingBeanDefinitionParser {
String hubId = element.getAttribute("hub-id");
// Factory will enable gateway if it is not set and hub-id is set.
if (StringUtils.hasText(enableGateway)) {
- if (ParsingUtils.GEMFIRE_VERSION.startsWith("7")) {
+ if (ParsingUtils.isGemfireV7OrAbove()) {
log.warn("'enable-gateway' is deprecated since Gemfire 7.0");
}
}
ParsingUtils.setPropertyValue(element, builder, "enable-gateway");
if (StringUtils.hasText(hubId)) {
- if (ParsingUtils.GEMFIRE_VERSION.startsWith("7")) {
+ if (ParsingUtils.isGemfireV7OrAbove()) {
log.warn("'hub-id' is deprecated since Gemfire 7.0");
}
if (!CollectionUtils.isEmpty(DomUtils.getChildElementsByTagName(element, "gateway-sender"))) {
diff --git a/src/main/java/org/springframework/data/gemfire/config/ParsingUtils.java b/src/main/java/org/springframework/data/gemfire/config/ParsingUtils.java
index f44a5e22..216b8b27 100644
--- a/src/main/java/org/springframework/data/gemfire/config/ParsingUtils.java
+++ b/src/main/java/org/springframework/data/gemfire/config/ParsingUtils.java
@@ -18,6 +18,8 @@ package org.springframework.data.gemfire.config;
import java.util.List;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
import org.springframework.beans.BeanMetadataAttribute;
import org.springframework.beans.factory.config.BeanDefinition;
import org.springframework.beans.factory.config.BeanDefinitionHolder;
@@ -48,6 +50,8 @@ import com.gemstone.gemfire.cache.Scope;
* @author David Turanski
*/
abstract class ParsingUtils {
+
+ private static Log log = LogFactory.getLog(ParsingUtils.class);
final static String GEMFIRE_VERSION = CacheFactory.getVersion();
@@ -309,6 +313,17 @@ abstract class ParsingUtils {
if (StringUtils.hasText(indexUpdateType)) {
attrBuilder.addPropertyValue("indexMaintenanceSynchronous", "synchronous".equals(indexUpdateType));
}
+
+ String concurrencyChecksEnabled = element.getAttribute("concurrency-checks-enabled");
+ if (StringUtils.hasText(concurrencyChecksEnabled)) {
+ if (!ParsingUtils.isGemfireV7OrAbove()) {
+ log.warn("'concurrency-checks-enabled' is only available in Gemfire 7.0 or above");
+ } else {
+ ParsingUtils.setPropertyValue(element, attrBuilder, "concurrency-checks-enabled");
+ }
+ }
+
+
}
static void parseMembershipAttributes(ParserContext parserContext, Element element,
@@ -339,8 +354,7 @@ abstract class ParsingUtils {
}
static void throwExceptionIfNotGemfireV7(String elementName, String attributeName, ParserContext parserContext) {
- boolean checkGemfireV7 = !GEMFIRE_VERSION.startsWith("7");
- if (checkGemfireV7) {
+ if (!isGemfireV7OrAbove()) {
String messagePrefix = (attributeName == null) ? "element '" + elementName + "'" : "attribute '"
+ attributeName + " of element '" + elementName + "'";
parserContext.getReaderContext().error(
@@ -348,6 +362,13 @@ abstract class ParsingUtils {
null);
}
}
+
+ static boolean isGemfireV7OrAbove() {
+
+ int version = Integer.parseInt(GEMFIRE_VERSION.substring(0,1));
+ return version >= 7;
+
+ }
static void parseScope(Element element, BeanDefinitionBuilder builder) {
String scope = element.getAttribute("scope");
diff --git a/src/main/resources/org/springframework/data/gemfire/config/spring-gemfire-1.2.xsd b/src/main/resources/org/springframework/data/gemfire/config/spring-gemfire-1.2.xsd
index 283b747e..455c9205 100755
--- a/src/main/resources/org/springframework/data/gemfire/config/spring-gemfire-1.2.xsd
+++ b/src/main/resources/org/springframework/data/gemfire/config/spring-gemfire-1.2.xsd
@@ -1064,6 +1064,16 @@ reduce thread contention. This sets an initial parameter on the underlying java.
]]>
+
+
+
+
+
+
+
diff --git a/src/test/java/org/springframework/data/gemfire/config/GemfireV7GatewayNamespaceTest.java b/src/test/java/org/springframework/data/gemfire/config/GemfireV7GatewayNamespaceTest.java
index c5134ece..560408b6 100644
--- a/src/test/java/org/springframework/data/gemfire/config/GemfireV7GatewayNamespaceTest.java
+++ b/src/test/java/org/springframework/data/gemfire/config/GemfireV7GatewayNamespaceTest.java
@@ -306,12 +306,6 @@ public class GemfireV7GatewayNamespaceTest extends RecreatingContextTest impleme
return this;
}
- @Override
- public AsyncEventQueueFactory setBatchTimeInterval(int arg0) {
- // TODO Auto-generated method stub
- return null;
- }
-
@Override
public AsyncEventQueueFactory setParallel(boolean arg0) {
// TODO Auto-generated method stub