summaryrefslogtreecommitdiffstats
path: root/nova/db/sqlalchemy/models.py
diff options
context:
space:
mode:
authorJenkins <jenkins@review.openstack.org>2013-06-11 02:39:43 +0000
committerGerrit Code Review <review@openstack.org>2013-06-11 02:39:43 +0000
commit45e80dfdb2a7ec1ad9bfa38f3761fd9086dcbca8 (patch)
tree2ce6ee4df4370097a7c210149d7902c40bbb9797 /nova/db/sqlalchemy/models.py
parente40f78b0daa2b78cea1be6262a21029f9cef8de7 (diff)
parent0d5fb06b39e8244429be72f05e2066d24572dc2e (diff)
downloadnova-45e80dfdb2a7ec1ad9bfa38f3761fd9086dcbca8.tar.gz
nova-45e80dfdb2a7ec1ad9bfa38f3761fd9086dcbca8.tar.xz
nova-45e80dfdb2a7ec1ad9bfa38f3761fd9086dcbca8.zip
Merge "DB migration to the new BDM data format"
Diffstat (limited to 'nova/db/sqlalchemy/models.py')
-rw-r--r--nova/db/sqlalchemy/models.py16
1 files changed, 12 insertions, 4 deletions
diff --git a/nova/db/sqlalchemy/models.py b/nova/db/sqlalchemy/models.py
index 418e05cfa..386fcbdad 100644
--- a/nova/db/sqlalchemy/models.py
+++ b/nova/db/sqlalchemy/models.py
@@ -446,7 +446,16 @@ class BlockDeviceMapping(BASE, NovaBase):
'Instance.uuid,'
'BlockDeviceMapping.deleted=='
'0)')
- device_name = Column(String(255), nullable=False)
+
+ source_type = Column(String(255))
+ destination_type = Column(String(255))
+ guest_format = Column(String(255))
+ device_type = Column(String(255))
+ disk_bus = Column(String(255))
+
+ boot_index = Column(Integer)
+
+ device_name = Column(String(255))
# default=False for compatibility of the existing code.
# With EC2 API,
@@ -454,14 +463,13 @@ class BlockDeviceMapping(BASE, NovaBase):
# default False for created with other timing.
delete_on_termination = Column(Boolean, default=False)
- # for ephemeral device
- virtual_name = Column(String(255), nullable=True)
-
snapshot_id = Column(String(36))
volume_id = Column(String(36), nullable=True)
volume_size = Column(Integer, nullable=True)
+ image_id = Column('image_id', String(36))
+
# for no device to suppress devices.
no_device = Column(Boolean, nullable=True)