From 250230b32364b1e36ae6d62ec4bb8c3285c59401 Mon Sep 17 00:00:00 2001 From: Andrew Laski Date: Tue, 15 Jan 2013 17:24:49 -0500 Subject: Record instance actions and events Record when an action is initiated on an instance, and the underlying events related to completing that action. Actions will typically occur at the API level and should match what a user intended to do with an instance. Events will typically track what happens behind the scenes and may include things that would be unclear for a user if exposed, but should be beneficial to an admin/deployer. Adds a new wrapper to the compute manager. The wrapper will record when an event begins and finishes from the point of view of the compute manager. It will also record errors if they occur. Blueprint instance-actions Change-Id: I801f3e796d091e146413f84c2ccfab95ad2e1af4 --- nova/db/sqlalchemy/models.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'nova/db/sqlalchemy/models.py') diff --git a/nova/db/sqlalchemy/models.py b/nova/db/sqlalchemy/models.py index fd8348678..e91988a95 100644 --- a/nova/db/sqlalchemy/models.py +++ b/nova/db/sqlalchemy/models.py @@ -1005,7 +1005,11 @@ class InstanceFault(BASE, NovaBase): class InstanceAction(BASE, NovaBase): - """Track client actions on an instance.""" + """Track client actions on an instance. + + The intention is that there will only be one of these per user request. A + lookup by (instance_uuid, request_id) should always return a single result. + """ __tablename__ = 'instance_actions' id = Column(Integer, primary_key=True, nullable=False, autoincrement=True) action = Column(String(255)) -- cgit