Clean up some verifier messages.

To make things a little more clear.
Also unifies the flavor_id to instance_flavor_id

Change-Id: I43a98965eb6b73f2333fc1f143d8f4f0dac702aa
This commit is contained in:
Sandy Walsh 2014-12-01 06:59:35 -08:00
parent e0256a3fdb
commit 657e358e0e
1 changed files with 4 additions and 4 deletions

View File

@ -118,7 +118,7 @@ class UsageHandler(PipelineHandlerBase):
break
if not exists:
raise UsageException("U0", "No .exists record.")
raise UsageException("U0", "No .exists notification found.")
return exists
@ -167,14 +167,14 @@ class UsageHandler(PipelineHandlerBase):
if deleted_at and state != "deleted":
raise UsageException("U3", ".exists state not 'deleted' but "
"deleted_at is set.")
".exists deleted_at is set.")
if deleted_at and not deleted:
# We've already confirmed it's in the "deleted" state.
launched_at = exists.get('launched_at')
if deleted_at < launched_at:
raise UsageException("U4",
".exists deleted_at < launched_at.")
".exists deleted_at < .exists launched_at.")
# Is the deleted_at within this audit period?
if (deleted_at >= self.audit_beginning
@ -211,7 +211,7 @@ class UsageHandler(PipelineHandlerBase):
def _get_core_fields(self):
"""Broken out so derived classes can define their
own trait list."""
return ['launched_at', 'instance_type_id', 'tenant_id',
return ['launched_at', 'instance_flavor_id', 'tenant_id',
'os_architecture', 'os_version', 'os_distro']
def _do_checks(self, exists, events):