Index violation error encounters while inserting a record to UserHistoryItem table after clicking recent issue history link.

XMLWordPrintable

    • 4

      Hi,

      This might occur depending on time lag.
      When looking sql dump log, two threads approximately at the same time delete and insert the same index UserHistoryItem record.
      I reproduced it not only on hsqldb but also on the supported external database (MySQL).

      This is part of the sql dump log:

      ... (snip) ...
      2009-06-23 18:09:46,947 [http-8080-Processor21] DELETE FROM PUBLIC.userhistoryitem WHERE entitytype='Issue' AND entityid='10010' AND USERNAME='ogawa'
      ... (snip) ...
      2009-06-23 18:09:46,979 [http-8080-Processor22] DELETE FROM PUBLIC.userhistoryitem WHERE entitytype='Issue' AND entityid='10010' AND USERNAME='ogawa'
      ... (snip) ...
      2009-06-23 18:09:46,994 [http-8080-Processor22] INSERT INTO PUBLIC.userhistoryitem (ID, entitytype, entityid, USERNAME, lastviewed) VALUES ('10030', 'Issue', '10010', 'ogawa', '1245748186979'
      ... (snip) ...
      2009-06-23 18:09:47,010 [http-8080-Processor21] INSERT INTO PUBLIC.userhistoryitem (ID, entitytype, entityid, USERNAME, lastviewed) VALUES ('10031', 'Issue', '10010', 'ogawa', '1245748186947'
                                                      -> Index violation occurs here !!!
      ... (snip) ...
      

            Assignee:
            Nick Menere [Atlassian] (Inactive)
            Reporter:
            Kan Ogawa
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: