1 Reply Latest reply on Jul 11, 2013 6:04 AM by Bond Chan

    [jboss eap 5.1.2] node's invalidation cache cleared by each other

    Bond Chan Novice

      greetings,

       

       

      I'm using jboss cahce 3.2.8 shiped with jboss eap 5.1.2:

       

      step 1: @node A click a link on the browser

                  -> 153 nodes with values at nodeA

                   -> 153 nodes without values at nodeB

       

      step 2: @node B click the same link on the browser

                  -> 153 nodes with values at nodeB

                  -> 153 nodes without values at nodeA

       

      Then loop the step1 and step2 having the same result of each, so one node always having no values, I tried MVCC and OPTIMISTIC, result is same.

       

      but OPTIMISTIC having the warning :

       

      2013-01-05 19:08:26,540 WARN  [org.jboss.cache.interceptors.InvalidationInterceptor] (main:) Unable to broadcast evicts as a part of the prepare phase.  Rolling back.

      org.jboss.cache.optimistic.DataVersioningException: Node found, but version is not equal to or less than the expected [Ver=1].  Is [Ver=2] instead!

              at org.jboss.cache.commands.legacy.write.VersionedInvalidateCommand.perform(VersionedInvalidateCommand.java:115)

              at org.jboss.cache.interceptors.CallInterceptor.invokeCommand(CallInterceptor.java:108)

              at org.jboss.cache.interceptors.CallInterceptor.handleDefault(CallInterceptor.java:99)

              at org.jboss.cache.commands.AbstractVisitor.visitInvalidateCommand(AbstractVisitor.java:90)

              at org.jboss.cache.commands.write.InvalidateCommand.acceptVisitor(InvalidateCommand.java:125)

        • 1. Re: [jboss eap 5.1.2] node's invalidation cache cleared by each other
          Bond Chan Novice

          Are we using the jboss invalidation cluster cache correctly ?

           

          -We using like this:

             int id = 500;

            Object value = cache.get("xx/yy/zz/500", "key");

            if(value == null){

              Object value = service.findById(500);

              cache.put("xx/yy/zz/500", "key", value);

          }

           

          --this issue now:

          when one server call "cache.put("xx/yy", key, value)", this node on other server were invalidated, so for every node, only the one server having data.

           

          --what we want

          when one server call "cache.put("xx/yy", key, value)" for node xx/yy at the 1st time, this node on other server were not invalidated, so 1st time call is like load data for this node, no effect to other servers, after calls are updating this node, then other servers should invalidated

           

          can we achieve this ?