Uploaded image for project: 'Crucible'
  1. Crucible
  2. CRUC-6577

Race condition when creating the FileReadStatus

    XMLWordPrintable

Details

    • Bug
    • Resolution: Timed out
    • Low
    • None
    • 2.10.0
    • None

    Description

      There are certain conditions that can lead to a BatchUpdateException when reading file or updating files (that would trigger read status to change).

      The exception can be displayed with various exceptions depending on the database driver being used. Examples:

      • java.sql.BatchUpdateException: Duplicate entry '9-1' for key 2
      • Duplicate entry '1476-4608' for key 'cru_participant'

      This is caused due to incorrect assumptions in the code. It is reproducable by:

      • create a review with 2 files
      • start the review
      • add a reviewer
      • read the first file as the reviewer
      • in 2 separate threads:
        • add a new revision to the second file
        • add a different new revision to the second file

      This can cause a race condition. The symptom of the failure is that the second update will fail. The user will be given a message saying that the update failed and that the action will need to be performed again.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              gcrain Geoff Crain (Inactive)
              Votes:
              3 Vote for this issue
              Watchers:
              9 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: