db.utils.create_shadow_table() doesn't work if we have table with Enum column

Bug #1194106 reported by Boris Pavlovic on 2013-06-24
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Low
Unassigned
oslo.db
Low
Unassigned

Bug Description

In postgres we are not able to create two times Enum with the same name.

So If we try to make a shadow table for table we will get exception that Enum with the same name already exists.

So we should rename our Enum.
I think that shadow_prefix + original_name will be good convention.

Changed in nova:
assignee: nobody → Boris Pavlovic (boris-42)
status: New → In Progress
Changed in nova:
importance: Undecided → Low
Changed in nova:
assignee: Boris Pavlovic (boris-42) → Yongli He (yongli-he)

Fix proposed to branch: master
Review: https://review.openstack.org/35098

Changed in nova:
assignee: Yongli He (yongli-he) → Boris Pavlovic (boris-42)
David Ripton (dripton) on 2013-11-07
tags: added: postgresql
David Ripton (dripton) wrote :

The first review was abandoned and the second review doesn't seem to exist. Does anyone have an update on this? Looks pretty serious if it breaks all migrations with an Enum on postgres.

Boris Pavlovic (boris-42) wrote :

At this moment we don't use Enum, so it is not important at all

Matt Riedemann (mriedem) wrote :

Should this be handled in oslo.db now if it's not already?

Changed in nova:
status: In Progress → Triaged
assignee: Boris Pavlovic (boris-42) → nobody
Sean Dague (sdague) wrote :

This code isn't in nova any more, moving to oslo.db

Changed in nova:
status: Triaged → Invalid
Changed in oslo.db:
status: New → Confirmed
importance: Undecided → Low
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers