Uploaded image for project: 'Nuxeo Platform'
  1. Nuxeo Platform
  2. NXP-26323

Avoid some types of ConcurrentUpdateException by writing rows in deterministic order

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 9.10, 10.2
    • Fix Version/s: 9.10-HF24, 10.10
    • Component/s: Core VCS, Quotas
    • Tags:
    • Backlog priority:
      900
    • Sprint:
      nxFG 10.10.2
    • Story Points:
      5

      Description

      When a process has two rows A and B to write to a SQL database, and this process is executed twice concurrently, and the order of the write of the rows is different in both processes (A then B in the first, and B then A in the second), then in a transactional setting a database deadlock will occur, be detected, and end up in a ConcurrentUpdateException at the Nuxeo level for the second transaction.

      One standard way of avoiding this is to write all rows in the same order in all transactions. We should modify VCS to do that.

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 1 day
                1d