summaryrefslogtreecommitdiffstats
path: root/etc/nova
diff options
context:
space:
mode:
authorClay Gerrard <clay.gerrard@gmail.com>2012-09-14 16:15:35 +0000
committerClay Gerrard <clay.gerrard@gmail.com>2012-09-14 16:40:03 -0500
commit4ebec877303048e8bb0c5ce7f68b587b2972ec3c (patch)
tree4a596895409fee1c44134a7dd67be6ff6049929c /etc/nova
parentd41b93267f2c0e31fa94c8ea185864b631142df4 (diff)
downloadnova-4ebec877303048e8bb0c5ce7f68b587b2972ec3c.tar.gz
nova-4ebec877303048e8bb0c5ce7f68b587b2972ec3c.tar.xz
nova-4ebec877303048e8bb0c5ce7f68b587b2972ec3c.zip
Add admin actions extension
The optional os-admin-actions extension adds new wsgi_actions to the volumes/action resource and a new snapshots/action endpoint. With this extension both controllers will support an os-reset_status action to force a database update of a volume or snapshot that is stuck in a failed/incorrect status. The os-reset_status action works similarly to the compute api's os-reset_state action for instances. The os-force_delete action behaves similarly to the "cinder-manage volume delete" command and allows operators/admins to retry the delete operation after it has gone into an error_deleting status with an admin api call. The os-admin-actions extension is enabled by default, but limited to the admin api by the default policy.json rules. Individual admin actions can be disabled with policy rules as well. Example of os-reset_status action on a volume: curl http://localhost:8776/v1/${PROJECT_ID}/volumes/${VOLUME_ID}/action \ -H "x-auth-token: ${ADMIN_AUTH_TOKEN}" \ -H 'content-type: application/json' \ -d '{"os-reset_status": {"status": "error"}}' The new admin only api can assist deployers who encounter bugs or operational issues that result in failed actions. It can also be used by future storage backends to support async callback style status updates from long running actions or operations which have encountered an error will be retried. Also updates the api.openstack.wsgi.ControllerMetaclass to support sub-classing wsgi.Controllers that define wsgi_actions. Partial fix for bug #1039706 Change-Id: If795599d5150dea362279d75a75276f3166d0149
Diffstat (limited to 'etc/nova')
-rw-r--r--etc/nova/policy.json3
1 files changed, 3 insertions, 0 deletions
diff --git a/etc/nova/policy.json b/etc/nova/policy.json
index 688918d66..a6936af08 100644
--- a/etc/nova/policy.json
+++ b/etc/nova/policy.json
@@ -76,6 +76,9 @@
"volume_extension:types_manage": [["rule:admin_api"]],
"volume_extension:types_extra_specs": [["rule:admin_api"]],
+ "volume_extension:volume_admin_actions:reset_status": [["rule:admin_api"]],
+ "volume_extension:snapshot_admin_actions:reset_status": [["rule:admin_api"]],
+ "volume_extension:volume_admin_actions:force_delete": [["rule:admin_api"]],
"network:get_all_networks": [],