Uploaded image for project: 'WildFly'
  1. WildFly
  2. WFLY-3682

SFSB DistributedCache doesn't commit when get(...) and release/discard(...) use different threads

    XMLWordPrintable

Details

    Description

      While investigating failures in org.jboss.as.test.manualmode.ejb.client.cluster.EJBClientClusterConfigurationTestCase following the upgrade to JGroups 3.5, I uncovered a number of critical bugs in the DistributedCache logic.

      • DistributedCache uses a thread-local stack to store the reference to a Batch across invocations of Cache get/release/discard(...). Consequently, Infinispan's transaction won't commit if Cache.get(...) was called from a different thread than Cache.release(...) or Cache.discard(...)
      • The implementation of the Batch SPI uses Infinispan's BatchContainer, which itself relies on thread locals to store references to the Transaction across calls to startBatch()/endBatch().
      • Once the above issues were address, I got an NPE in InfinispanBeanEntryExternalizer.writeObject(...) when the lastAccessedTime is null (which is the case following creation).

      Attachments

        Activity

          People

            pferraro@redhat.com Paul Ferraro
            pferraro@redhat.com Paul Ferraro
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: