Uploaded image for project: 'Infinispan'
  1. Infinispan
  2. ISPN-849

testTransactional doesn't ever work

    XMLWordPrintable

Details

    • Bug
    • Resolution: Duplicate
    • Major
    • None
    • None
    • None
    • None

    Description

      I'm triing testTransactional inside distribution.rehash.ConcurrentNonOverlappingLeaveTest . Often it doesn't update the c1 cache with the value "transactionally_replaced" instead of "v1".

      I thought about a syncronization problem of the Threads but I see that the put of the field always is executed before the get. Actually the problem seems be in org.infinispan.distribution.rehash.RehashTestBase class (95-109):

      TransactionManager t1 = TestingUtil.getTransactionManager(c1);
      t1.begin();
      c1.put(keys.get(0), "transactionally_replaced");
      Transaction tx = t1.getTransaction();
      tx.enlistResource(new XAResourceAdapter() {
      public int prepare(Xid id) {
      // this would be called after the cache prepares.
      try

      { l.await(); }

      catch (InterruptedException e) {
      }
      return XAResource.XA_OK;
      }
      });
      t1.commit();

      maybe sometime there is a rollback

      Attachments

        Activity

          People

            manik_jira Manik Surtani (Inactive)
            luca.stancapiano@vige.it Luca Stancapiano (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: