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

Pre-modified event on invalidation cache does not contain the value

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Out of Date
    • Affects Version/s: 8.0.1.Final
    • Fix Version/s: None
    • Component/s: Listeners
    • Labels:
      None

      Description

      I have a cache listener on an invalidation-mode cache. If a cache entry gets replaced on the same node, two CacheEntryModifiedEvents are fired. The pre event returns null instead of returning the old value as it is supposed to. (The pre event correctly returned the old value in Infinispan 6, which we are upgrading from.) The post event appears to contain the correct old value, but getOldValue() is not available on CacheEntryModifiedEvent so you have to cast to EventImpl.

      11:24:02,199 INFO  [stdout] (default task-1) EventImpl{type=CACHE_ENTRY_MODIFIED, pre=true, cache=Cache 'SONGv1-localRouting'@galactica, key=1.2.3.4.5.6, value=null, oldValue=null, transaction=GlobalTransaction:<galactica>:5:local, originLocal=true, transactionSuccessful=false, entries=null, created=false}
      11:24:02,219 INFO  [stdout] (default task-1) EventImpl{type=CACHE_ENTRY_MODIFIED, pre=false, cache=Cache 'SONGv1-localRouting'@galactica, key=1.2.3.4.5.6, value=[id: 0xembedded, embedded => embedded], oldValue=[id: 0xembedded, embedded => embedded], transaction=GlobalTransaction:<galactica>:5:local, originLocal=true, transactionSuccessful=false, entries=null, created=false}
      

        Attachments

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            rcd Richard DiCroce
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: