[infinispan-issues] [JBoss JIRA] (ISPN-11122) CacheMode.INVALIDATION_SYNC is being replicated

Dan Berindei (Jira) issues at jboss.org
Mon Jan 6 18:40:06 EST 2020


     [ https://issues.redhat.com/browse/ISPN-11122?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Dan Berindei resolved ISPN-11122.
---------------------------------
    Resolution: Explained


[~glira] you forgot to mention that the cache is backed by a shared JDBC store.

The entries inserted on {{cache1}} go into the shared store, where they can be seen by both {{cache1}} and {{cache2}}. And even in invalidation mode, {{cache.size()}} includes both the entries in memory and the entries in the shared store.

> CacheMode.INVALIDATION_SYNC is being replicated
> -----------------------------------------------
>
>                 Key: ISPN-11122
>                 URL: https://issues.redhat.com/browse/ISPN-11122
>             Project: Infinispan
>          Issue Type: Bug
>    Affects Versions: 10.1.0.Final
>            Reporter: Gustavo Lira e Silva
>            Priority: Major
>
> Configuring two remote caches with hotrod and CacheMode.INVALIDATION_SYNC using InfinispanServerRule, populate cache1, cache2 should contain size=0, but all cache1 is being replicated to cache2.
> {code:java}
> RemoteCache<String, String> cache1 = SERVER_TEST.hotrod().withServerConfiguration(builder).withClientConfiguration(clientBuilder1).create();
> RemoteCache<String, String> cache2 = SERVER_TEST.hotrod().withServerConfiguration(builder).withClientConfiguration(clientBuilder2).create();
> cache1.put("key", "value");
> assertEquals("value", cache1.get("key"));
> assertEquals(1, cache1.size());
> assertEquals(0, cache2.size()); // is failling
> {code}



--
This message was sent by Atlassian Jira
(v7.13.8#713008)


More information about the infinispan-issues mailing list