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

duplicated null cru_stored_path rows leads to 3.0 upgrade problems

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Low
    • 3.0.1
    • 3.0.0
    • Server administration
    • None

    Description

      There is unfortunate scenario possible leading to 3.0 upgrade failing halfway through. Moreover after restarting Fisheye it seems like it is continuing the upgrade and is becoming fully operational, while it is not.

      Issue would affect users with more than one null stored path row trying to upgrade to 3.0.0 release

      select count(*) from cru_stored_path t where t.cru_path is null
      

      When they upgrade their instance they would see a fatal error preventing upgrade to finish:

      FATAL - Hash (SHA-256) conflict found: StoredPath(null) is found to have same hash [null] as path [null]
      

      But because upgrade task is run after sql db upgrade script is run, the persisted data would indicate the upgrade was successful. So next time user tries to start Fisheye it would continue upgrade from the next step, even though current step is incomplete ... And because it is incomplete unique index on cru_stored_path.cru_hash column would be never set. that would lead to further duplicated paths leading to errors like:

      An org.hibernate.NonUniqueResultException was encountered
      query did not return a unique result: 2
      

      Attachments

        Issue Links

          Activity

            People

              pswiecicki Piotr Swiecicki
              pswiecicki Piotr Swiecicki
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - Not Specified
                  Not Specified
                  Logged:
                  Time Spent - 43m
                  43m