INT-3913 Remove/resolve deprecation from the past

JIRA: https://jira.spring.io/browse/INT-3913

* Remove deprecated classes and methods/constructors, deprecated XML attributes
* Remove `TcpConnectionEventListeningMessageProducer` and rework tests logic to the `ApplicationEventListeningMessageProducer`
* Fix several typos
* Remove/rework deprecated entities mentioning
This commit is contained in:
Artem Bilan
2016-08-26 12:56:11 -04:00
committed by Gary Russell
parent ea4763faa9
commit eaed954458
87 changed files with 106 additions and 1765 deletions

View File

@@ -62,25 +62,12 @@ public class GemfireMessageStore extends AbstractKeyValueMessageStore implements
this.messageStoreRegion = messageStoreRegion;
}
/**
* Provides a cache reference used to create a message store region named
* 'messageStoreRegion'
* @param cache The cache.
*
* @deprecated - use the other constructor and provide a region directly.
*/
@Deprecated
public GemfireMessageStore(Cache cache) {
Assert.notNull(cache, "'cache' must not be null");
this.cache = cache;
}
public void setIgnoreJta(boolean ignoreJta) {
this.ignoreJta = ignoreJta;
}
@Override
@SuppressWarnings({ "unchecked", "deprecation" })
@SuppressWarnings("unchecked")
public void afterPropertiesSet() {
if (this.messageStoreRegion != null) {
return;

View File

@@ -7,7 +7,7 @@
<beans:bean id="messageStore" class="org.springframework.integration.gemfire.store.GemfireMessageStore">
<beans:constructor-arg
value="#{T (org.springframework.integration.gemfire.store.DelayerHandlerRescheduleIntegrationTests).cacheFactoryBean.object}"/>
value="#{T (org.springframework.integration.gemfire.store.DelayerHandlerRescheduleIntegrationTests).region}"/>
</beans:bean>
<channel id="output">

View File

@@ -43,6 +43,10 @@ import org.springframework.messaging.MessageChannel;
import org.springframework.messaging.PollableChannel;
import org.springframework.scheduling.concurrent.ThreadPoolTaskScheduler;
import com.gemstone.gemfire.cache.Cache;
import com.gemstone.gemfire.cache.Region;
import com.gemstone.gemfire.cache.Scope;
/**
* @author Artem Bilan
@@ -53,7 +57,9 @@ public class DelayerHandlerRescheduleIntegrationTests {
public static final String DELAYER_ID = "delayerWithGemfireMS";
public static CacheFactoryBean cacheFactoryBean;
public static Region<Object, Object> region;
private static CacheFactoryBean cacheFactoryBean;
@ClassRule
public static LongRunningIntegrationTest longTests = new LongRunningIntegrationTest();
@@ -62,10 +68,15 @@ public class DelayerHandlerRescheduleIntegrationTests {
public static void startUp() throws Exception {
cacheFactoryBean = new CacheFactoryBean();
cacheFactoryBean.afterPropertiesSet();
Cache cache = cacheFactoryBean.getObject();
region = cache.createRegionFactory().setScope(Scope.LOCAL).create("sig-tests");
}
@AfterClass
public static void cleanUp() throws Exception {
if (region != null) {
region.close();
}
if (cacheFactoryBean != null) {
cacheFactoryBean.destroy();
}

View File

@@ -62,9 +62,9 @@ import junit.framework.AssertionFailedError;
*/
public class GemfireGroupStoreTests {
public static CacheFactoryBean cacheFactoryBean;
private static CacheFactoryBean cacheFactoryBean;
private static Region<Object, Object> region;
public static Region<Object, Object> region;
@Test
public void testNonExistingEmptyMessageGroup() throws Exception {

View File

@@ -13,7 +13,7 @@
<bean id="gemfireStore" class="org.springframework.integration.gemfire.store.GemfireMessageStore">
<constructor-arg
value="#{T (org.springframework.integration.gemfire.store.GemfireGroupStoreTests).cacheFactoryBean.object}"/>
value="#{T (org.springframework.integration.gemfire.store.GemfireGroupStoreTests).region}"/>
</bean>
</beans>

View File

@@ -13,7 +13,7 @@
<bean id="gemfireStore" class="org.springframework.integration.gemfire.store.GemfireMessageStore">
<constructor-arg
value="#{T (org.springframework.integration.gemfire.store.GemfireGroupStoreTests).cacheFactoryBean.object}"/>
value="#{T (org.springframework.integration.gemfire.store.GemfireGroupStoreTests).region}"/>
</bean>
</beans>

View File

@@ -20,7 +20,7 @@
<bean id="gemfireStore" class="org.springframework.integration.gemfire.store.GemfireMessageStore">
<constructor-arg
value="#{T (org.springframework.integration.gemfire.store.GemfireGroupStoreTests).cacheFactoryBean.object}"/>
value="#{T (org.springframework.integration.gemfire.store.GemfireGroupStoreTests).region}"/>
</bean>
</beans>