summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVishvananda Ishaya <vishvananda@yahoo.com>2010-09-12 04:48:49 -0700
committerVishvananda Ishaya <vishvananda@yahoo.com>2010-09-12 04:48:49 -0700
commite77e8a4c368a5c4da1f3e64938bc8940c3603418 (patch)
tree66ce3b2f50223533c05c02bdb8c9cb82c780aa93
parentfa4c69330585ead1a1dd58b3bec4cc3f0f92082c (diff)
downloadnova-e77e8a4c368a5c4da1f3e64938bc8940c3603418.tar.gz
nova-e77e8a4c368a5c4da1f3e64938bc8940c3603418.tar.xz
nova-e77e8a4c368a5c4da1f3e64938bc8940c3603418.zip
fixed name for unique constraint
-rw-r--r--nova/db/sqlalchemy/models.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/nova/db/sqlalchemy/models.py b/nova/db/sqlalchemy/models.py
index b6a8c134a..a6c7d83c0 100644
--- a/nova/db/sqlalchemy/models.py
+++ b/nova/db/sqlalchemy/models.py
@@ -315,7 +315,7 @@ class Quota(BASE, NovaBase):
class ExportDevice(BASE, NovaBase):
"""Represates a shelf and blade that a volume can be exported on"""
__tablename__ = 'export_devices'
- __table_args__ = (schema.UniqueConstraint("name", "site"), {'mysql_engine': 'InnoDB'})
+ __table_args__ = (schema.UniqueConstraint("shelf_id", "blade_id"), {'mysql_engine': 'InnoDB'})
id = Column(Integer, primary_key=True)
shelf_id = Column(Integer)
blade_id = Column(Integer)