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

Write skew check throws even if the previous value was not read

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Major
    • 9.0.0.Final
    • 8.2.6.Final, 9.0.0.CR2
    • Core, Transactions
    • None

    Description

      When the entry was overwritten without reading previous value and then we read it (this read is handled from the current context), write skew check is still applied and can fail, despite that it's unnecessary.

      cache.put("k", "init");
      
      tm.begin();
      cache.getAdvancedCache().withFlags(Flag.IGNORE_RETURN_VALUES).put("k", "v1");
      assertEquals("v1", cache.put("k", "v2"));
      Transaction tx = tm.suspend();
      
      assertEquals("init", cache.put("k", "other"));
      
      tm.resume(tx);
      tm.commit(); // fails with WriteSkewCheckException
      

      Attachments

        Activity

          People

            rvansa1@redhat.com Radim Vansa (Inactive)
            rvansa1@redhat.com Radim Vansa (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: