2 Replies Latest reply on Mar 4, 2019 6:17 AM by dan.berindei

    How to disable the state transfer for the Cache mode INVALIDATION_ASYNC ?

    chillax

      We get many errors for the state transfer, although we use the INVALIDATION_ASYNC cache mode and do not want the state transfer to take place between the nodes on the clusters. The errors are like below:

       

      I suppose there shouldn't be any state transfer when using the INVALIDATION_ASYNC cache mode.

       

      From the documentation of org.infinispan.configuration.cacheStateTransferConfigurationBuilder.stateTransfer():

      Configure the stateTransfer sub element for distributed and replicated caches.It doesn't have any effect on LOCAL or INVALIDATION-mode caches.

      So why is it that is doing the state transfer and is there a way to disable it? We are using infinispan version 9.2.5

       

      Errors:

       

      org.infinispan.commons.CacheException: Unable to invoke method public void org.infinispan.statetransfer.StateTransferManagerImpl.waitForInitialStateTransferToComplete() throws java.lang.Exception on object of type StateTransferManagerImpl

              at org.infinispan.commons.util.SecurityActions.lambda$invokeAccessibly$0(SecurityActions.java:83) ~[infinispan-commons-9.2.5.Final.jar:9.2.5.Final]

              at org.infinispan.commons.util.SecurityActions.doPrivileged(SecurityActions.java:71) ~[infinispan-commons-9.2.5.Final.jar:9.2.5.Final]

              at org.infinispan.commons.util.SecurityActions.invokeAccessibly(SecurityActions.java:76) ~[infinispan-commons-9.2.5.Final.jar:9.2.5.Final]

              at org.infinispan.commons.util.ReflectionUtil.invokeAccessibly(ReflectionUtil.java:185) ~[infinispan-commons-9.2.5.Final.jar:9.2.5.Final]

              at org.infinispan.factories.AbstractComponentRegistry$PrioritizedMethod.invoke(AbstractComponentRegistry.java:968) ~[infinispan-core-9.2.5.Final.jar:9.2.5.Final]

              at org.infinispan.factories.AbstractComponentRegistry.lambda$invokePrioritizedMethods$6(AbstractComponentRegistry.java:703) ~[infinispan-core-9.2.5.Final.jar:9.2.5.Final]

              at org.infinispan.factories.SecurityActions.lambda$run$1(SecurityActions.java:72) ~[infinispan-core-9.2.5.Final.jar:9.2.5.Final]

              at org.infinispan.security.Security.doPrivileged(Security.java:76) ~[infinispan-core-9.2.5.Final.jar:9.2.5.Final]

              at org.infinispan.factories.SecurityActions.run(SecurityActions.java:71) ~[infinispan-core-9.2.5.Final.jar:9.2.5.Final]

      Caused by: org.infinispan.commons.CacheException: Initial state transfer timed out for cache recording_resolution on CONTROL_V2_SERVICE-42701-17249

              at org.infinispan.statetransfer.StateTransferManagerImpl.waitForInitialStateTransferToComplete(StateTransferManagerImpl.java:233) ~[infinispan-core-9.2.5.Final.jar:9.2.5.Final]

              at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_191]

              at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_191]

              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_191]

              at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_191]

              at org.infinispan.commons.util.SecurityActions.lambda$invokeAccessibly$0(SecurityActions.java:79) ~[infinispan-commons-9.2.5.Final.jar:9.2.5.Final]

              ... 40 more

        • 1. Re: How to disable the state transfer for the Cache mode INVALIDATION_ASYNC ?
          ahmed.reda007

          I have the same issue still looking for solution.

           

          I have read something about increasing number of threads as workaround but still I cannot get what could be the reason for state transfer in case of invalidation cache.

          • 2. Re: How to disable the state transfer for the Cache mode INVALIDATION_ASYNC ?
            dan.berindei

            Hi Ajmal, Ahmed

             

            The documentation is correct, state transfer is always disabled in invalidation caches.

             

            The error message is wrong: the cache was just waiting for the cluster coordinator to confirm that the node has joined the cache, and the topology update message from the coordinator did not arrive in `configuration.clustering().stateTransfer().timeout()` milliseconds.

             

            One possibility is that your stack uses UDP and multicasting, but multicasting does not work in your environment. You may also be hitting a bug in Infinispan. If you can reproduce it with the latest 9.4.x release, please enable DEBUG logging for `org.infinispan` and post the logs and configuration here.