0 Replies Latest reply on Dec 24, 2014 10:09 AM by stupormundi

    Infinispan commits in the context of jboss web service operations

    stupormundi Newbie

      [ Infinispan 5.2.8.Final, in JBoss EAP 6.3 ]

       

      Hello Forum!

       

      I have, in JBoss EAP 6.3, @Webservice and @Stateless annotated web services, and @WebResult annotated web operations.

       

      When, triggered from such a web operation, adding nodes to a replicated Infinispan cache, and setting values (but indirectly, through infinispan-tree, i.e., Node.put(Object arg1,Object arg2) ), I found to my surprise:

       

      accessing the cache a few tens of milliseconds later, from a different thread (another web operation in a different web service), but on the same machine (slave, in domain), the newly created node sometimes couldn't be retrieved.

       

      The cache is configured as replicated but otherwise default, which I believe means READ_COMMITTED.

       

      Since I'm using infinspan-tree methods to create the node ( Fqn.fromElements(arg) ) and set values, I'm uncertain when commit is expected to happen in such a case.

       

      Is it, as in JPA, at the end of websevice operation? (I haven't done any JTA config, so it is whatever default is)

       

      Is there no transaction and the node is expected to exist as soon as the call is made?

       

      Is there some asynchronicity going on?

       

       

       

      Was I wrong to expect a guarantee to be able to see the cache node after having completed the web service operation which creates the node?

       

      Or is the expectation ok and there is a bug?