Uploaded image for project: 'JBoss Enterprise Application Platform'
  1. JBoss Enterprise Application Platform
  2. JBEAP-23095

(8.0.z) Data race in EntryWrappingInterceptor handling expired entries

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Major
    • 8.0.0.Beta-CR1, 8.0.0.Beta
    • 7.4.0.GA, 7.4.2.GA
    • Server
    • None
    • False
    • False
    • Rejected
    • Hide
      If caches are used by applications the underlying Infinispan code is not working correctly.
      This will happen if expiration is used in combination with *All (put get) cache access.
      Show
      If caches are used by applications the underlying Infinispan code is not working correctly. This will happen if expiration is used in combination with *All (put get) cache access.

    Description

      EntryWrappingInterceptor.visitPutMapCommand processes the potential expiration of keys in the input map in parallel, and wraps the entries in the context in the threads that processed the expiration response.

      But NonTxInvocationContext is not thread-safe, as it uses a HashMap internally. When a PutMapCommand affects 2 or more entries can can both expire, and their keys map to the same HashMap bucket, one of the updates may be lost and the distribution interceptor will later fail with an IllegalStateException: Entry should be always wrapped!.

      Attachments

        Issue Links

          Activity

            People

              thofman Tomas Hofman
              thofman Tomas Hofman
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: