duplicate key error for mysql >=8.0.19 are not parsed correctly

Bug #1896916 reported by Koichiro Den
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
oslo.db
Fix Released
Undecided
Unassigned

Bug Description

Since mysql-server 8.0.19, table name is added in Duplicate Key Error messages [1]. Users of DBDuplicateEntry.columns will be potentially affected (or broken) by unsuccessfully parsed messages [2]. One head-scratcher is the fact that table names could potentially contain dot(s), especially when UniqueConstraint name convention is not applied.

[1]: https://github.com/mysql/mysql-server/commit/045af147eb32a657c0c7a8d10abb08dcd6055332
[2]: For instance, https://bugs.launchpad.net/tacker/+bug/1896867

Changed in oslo.db:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to oslo.db (master)

Reviewed: https://review.opendev.org/c/openstack/oslo.db/+/792124
Committed: https://opendev.org/openstack/oslo.db/commit/2c2e6d48ace2d91dce94d2e62fb0bdda904bc2bd
Submitter: "Zuul (22348)"
Branch: master

commit 2c2e6d48ace2d91dce94d2e62fb0bdda904bc2bd
Author: Kamlesh Chauvhan <email address hidden>
Date: Wed May 19 10:41:16 2021 +0000

    Added handler for mysql 8.0.19 duplicate key error update

    In mysql 8.0.19 , Duplicate key error information is extended to
    include the table name of the key.Previously, duplicate key error
    information included only the key value and key name.

    Unit tests are provided for updated changes.

    Change-Id: Ic78059b625e73cece355541cb4d89e641abc1103
    Closes-Bug: #1896916

Changed in oslo.db:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/oslo.db 9.1.0

This issue was fixed in the openstack/oslo.db 9.1.0 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to oslo.db (stable/wallaby)

Fix proposed to branch: stable/wallaby
Review: https://review.opendev.org/c/openstack/oslo.db/+/798760

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to oslo.db (stable/victoria)

Fix proposed to branch: stable/victoria
Review: https://review.opendev.org/c/openstack/oslo.db/+/798761

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to oslo.db (stable/ussuri)

Fix proposed to branch: stable/ussuri
Review: https://review.opendev.org/c/openstack/oslo.db/+/798762

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to oslo.db (stable/wallaby)

Reviewed: https://review.opendev.org/c/openstack/oslo.db/+/798760
Committed: https://opendev.org/openstack/oslo.db/commit/b32b643acc0528099a88504d4d824cdc002a85df
Submitter: "Zuul (22348)"
Branch: stable/wallaby

commit b32b643acc0528099a88504d4d824cdc002a85df
Author: Kamlesh Chauvhan <email address hidden>
Date: Wed May 19 10:41:16 2021 +0000

    Added handler for mysql 8.0.19 duplicate key error update

    In mysql 8.0.19 , Duplicate key error information is extended to
    include the table name of the key.Previously, duplicate key error
    information included only the key value and key name.

    Unit tests are provided for updated changes.

    Change-Id: Ic78059b625e73cece355541cb4d89e641abc1103
    Closes-Bug: #1896916
    (cherry picked from commit 2c2e6d48ace2d91dce94d2e62fb0bdda904bc2bd)

tags: added: in-stable-wallaby
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to oslo.db (stable/victoria)

Reviewed: https://review.opendev.org/c/openstack/oslo.db/+/798761
Committed: https://opendev.org/openstack/oslo.db/commit/8867e335da5451779d54a05e3f6194a3361582af
Submitter: "Zuul (22348)"
Branch: stable/victoria

commit 8867e335da5451779d54a05e3f6194a3361582af
Author: Kamlesh Chauvhan <email address hidden>
Date: Wed May 19 10:41:16 2021 +0000

    Added handler for mysql 8.0.19 duplicate key error update

    In mysql 8.0.19 , Duplicate key error information is extended to
    include the table name of the key.Previously, duplicate key error
    information included only the key value and key name.

    Unit tests are provided for updated changes.

    Change-Id: Ic78059b625e73cece355541cb4d89e641abc1103
    Closes-Bug: #1896916
    (cherry picked from commit 2c2e6d48ace2d91dce94d2e62fb0bdda904bc2bd)
    (cherry picked from commit b32b643acc0528099a88504d4d824cdc002a85df)

tags: added: in-stable-victoria
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/oslo.db 8.5.1

This issue was fixed in the openstack/oslo.db 8.5.1 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/oslo.db 8.4.1

This issue was fixed in the openstack/oslo.db 8.4.1 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to oslo.db (stable/ussuri)

Reviewed: https://review.opendev.org/c/openstack/oslo.db/+/798762
Committed: https://opendev.org/openstack/oslo.db/commit/79bfbd6ec7705ca558c34b6e368f95d93ddf94b0
Submitter: "Zuul (22348)"
Branch: stable/ussuri

commit 79bfbd6ec7705ca558c34b6e368f95d93ddf94b0
Author: Kamlesh Chauvhan <email address hidden>
Date: Wed May 19 10:41:16 2021 +0000

    Added handler for mysql 8.0.19 duplicate key error update

    In mysql 8.0.19 , Duplicate key error information is extended to
    include the table name of the key.Previously, duplicate key error
    information included only the key value and key name.

    Unit tests are provided for updated changes.

    Change-Id: Ic78059b625e73cece355541cb4d89e641abc1103
    Closes-Bug: #1896916
    (cherry picked from commit 2c2e6d48ace2d91dce94d2e62fb0bdda904bc2bd)
    (cherry picked from commit b32b643acc0528099a88504d4d824cdc002a85df)
    (cherry picked from commit 8867e335da5451779d54a05e3f6194a3361582af)

tags: added: in-stable-ussuri
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/oslo.db 8.1.1

This issue was fixed in the openstack/oslo.db 8.1.1 release.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.