Volumes Redux.

Makes all volume-service interactions optional (includes
volumes displays and volumes portion of launch workflow).

Splits Instances & Volumes into separate panels to
facilitate Volumes being optional.

Adds an admin Volumes panel to complement the user
Volumes panel.

Adds the capability to mark Steps in a Workflow as
requiring a given service.

Implements blueprint nova-volume-optional.

Change-Id: I3fb4255617ae52be64e7a300afd691dc36b95586
This commit is contained in:
Gabriel Hurley
2012-06-26 13:32:40 -07:00
parent 010475bbcd
commit 2c0a8f3220
65 changed files with 475 additions and 462 deletions

View File

@@ -64,6 +64,7 @@ class ActionMetaclass(forms.forms.DeclarativeFieldsMetaclass):
attrs['name'] = getattr(opts, "name", name)
attrs['slug'] = getattr(opts, "slug", slugify(name))
attrs['roles'] = getattr(opts, "roles", ())
attrs['services'] = getattr(opts, "services", ())
attrs['progress_message'] = getattr(opts,
"progress_message",
_("Processing..."))
@@ -112,6 +113,11 @@ class Action(forms.Form):
A list of role names which this action requires in order to be
completed. Defaults to an empty list (``[]``).
.. attribute:: services
A list of service types which this action requires in order to be
completed. Defaults to an empty list (``[]``).
.. attribute:: help_text
A string of simple help text to be displayed alongside the Action's
@@ -257,6 +263,10 @@ class Step(object):
.. attribute:: roles
Inherited from the ``Action`` class.
.. attribute:: services
Inherited from the ``Action`` class.
"""
action_class = None
depends_on = ()
@@ -284,6 +294,7 @@ class Step(object):
self.slug = self.action_class.slug
self.name = self.action_class.name
self.roles = self.action_class.roles
self.services = self.action_class.services
self.has_errors = False
self._handlers = {}