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

Internal change token for optimistic locking

    XMLWordPrintable

    Details

    • Type: New Feature
    • Status: Resolved
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 8.2
    • Fix Version/s: 9.1
    • Component/s: Clustering, Core
    • Epic Link:
    • Impact type:
      API change
    • Upgrade notes:
      Hide

      New API:

      • DocumentModel.getChangeToken()
        New behavior:
      • calling doc.putContextData(CoreSession.CHANGE_TOKEN, token) then CoreSession.saveDocument(doc) will check the change token and raise ConcurrentUpdateException in case of mismatch.
      Show
      New API: DocumentModel.getChangeToken() New behavior: calling doc.putContextData(CoreSession.CHANGE_TOKEN, token) then CoreSession.saveDocument(doc) will check the change token and raise ConcurrentUpdateException in case of mismatch.
    • Sprint:
      nxFG 9.1.6, nxFG 9.1.7, nxFG 9.1.8, nxFG 9.1.9, nxFG 9.1.10
    • Story Points:
      5

      Description

      Having an auto incremented change token on a document on each write operation will help to implement optimistic version control pattern.

      It will be also useful to keep Elasticsearch index in sync.

      For 9.1 this feature is disabled by default. Running tests with nuxeo.test.changetoken.enabled=true will activate it.

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                1 Vote for this issue
                Watchers:
                6 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: