113
113
availability_zone = Column(String(255), default='nova')
116
class ComputeNode(BASE, NovaBase):
117
"""Represents a running compute service on a host."""
119
__tablename__ = 'compute_nodes'
120
id = Column(Integer, primary_key=True)
121
service_id = Column(Integer, ForeignKey('services.id'), nullable=True)
122
service = relationship(Service,
123
backref=backref('compute_node'),
124
foreign_keys=service_id,
126
'ComputeNode.service_id == Service.id,'
127
'ComputeNode.deleted == False)')
129
vcpus = Column(Integer, nullable=True)
130
memory_mb = Column(Integer, nullable=True)
131
local_gb = Column(Integer, nullable=True)
132
vcpus_used = Column(Integer, nullable=True)
133
memory_mb_used = Column(Integer, nullable=True)
134
local_gb_used = Column(Integer, nullable=True)
135
hypervisor_type = Column(Text, nullable=True)
136
hypervisor_version = Column(Integer, nullable=True)
138
# Note(masumotok): Expected Strings example:
142
# "topology":{"sockets":1, "threads":2, "cores":3},
143
# "features":["tdtscp", "xtpr"]}'
145
# Points are "json translatable" and it must have all dictionary keys
146
# above, since it is copied from <cpu> tag of getCapabilities()
147
# (See libvirt.virtConnection).
148
cpu_info = Column(Text, nullable=True)
116
151
class Certificate(BASE, NovaBase):
117
152
"""Represents a an x509 certificate"""
118
153
__tablename__ = 'certificates'
191
226
display_name = Column(String(255))
192
227
display_description = Column(String(255))
229
# To remember on which host a instance booted.
230
# An instance may have moved to another host by live migraiton.
231
launched_on = Column(Text)
194
232
locked = Column(Boolean)
234
os_type = Column(String(255))
196
236
# TODO(vish): see Ewan's email about state improvements, probably
197
237
# should be in a driver base class or some such
198
238
# vmstate_state = running, halted, suspended, paused