Review main Merged

52398[BUGFIX] Fix non-unique hash values in SysRefindexHashUpdater

Morton Jonuschat CR +2 V +2 Normal +68 −0 updated 09/07/17, 08:52

Commit message

The new hash calculation can result in non-unique hash values when
updating old hashes. This is due to the new algorithm ignoring
the sorting fields while it was taken into account in the old one.
When two rows in the database (using the old hash format) only
differ in the sorting field (and the derived hash) the new hash
will be identical for both rows.
Due to the hash value being the primary key which needs to be
unique this will result in errors during the update.

This change adds an SQL call to remove the offending rows from
the database before proceeding to update the hash values.
Statement has been validated on MySQL and PostgreSQL.

Review

  • Code review CR +2

    Imported before Forger kept the single votes, the next import adds them.

  • Verified V +2

    Imported before Forger kept the single votes, the next import adds them.

Issues 1

Files 1