enable_[v1|v2]_api does not modify versions API response

Bug #1181413 reported by Brian Waldon on 2013-05-17
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Brian Waldon

Bug Description

I set enable_v2_api=false yet if I GET /, I see the following response:

{"versions": [{"status": "CURRENT", "updated": "2012-01-04T11:33:21Z", "id": "v1.0", "links": [{"href": "http://localhost:8776/v1/", "rel": "self"}]}, {"status": "CURRENT", "updated": "2012-11-21T11:33:21Z", "id": "v2.0", "links": [{"href": "http://localhost:8776/v1/", "rel": "self"}]}]}

Additionally, if I GET /versions, I see this:

{"choices": [{"status": "CURRENT", "media-types": [{"base": "application/xml", "type": "application/vnd.openstack.volume+xml;version=1"}, {"base": "application/json", "type": "application/vnd.openstack.volume+json;version=1"}], "id": "v1.0", "links": [{"href": "http://localhost:8776/v1/volumes", "rel": "self"}]}, {"status": "CURRENT", "media-types": [{"base": "application/xml", "type": "application/vnd.openstack.volume+xml;version=1"}, {"base": "application/json", "type": "application/vnd.openstack.volume+json;version=1"}], "id": "v2.0", "links": [{"href": "http://localhost:8776/v1/volumes", "rel": "self"}]}]}

I would expect the v2 version objects not to be present. The same would apply to the v1 version objects if enable_v1_api were set to true

Brian Waldon (bcwaldon) on 2013-05-17
Changed in cinder:
assignee: nobody → Brian Waldon (bcwaldon)

Fix proposed to branch: master
Review: https://review.openstack.org/29616

Changed in cinder:
status: New → In Progress
tags: added: grizzly-backport-potential

Reviewed: https://review.openstack.org/29616
Committed: http://github.com/openstack/cinder/commit/c2ee6e2187e258da07e229e690afe20f0039e019
Submitter: Jenkins
Branch: master

commit c2ee6e2187e258da07e229e690afe20f0039e019
Author: Brian Waldon <email address hidden>
Date: Fri May 17 22:42:45 2013 +0000

    Hide v1/v2 version entities in API when disabled

    Fixes bug 1181413

    Change-Id: Ia8aaa78a0e0d222c268e9ca780816eb1c26feb3f

Changed in cinder:
status: In Progress → Fix Committed
Thierry Carrez (ttx) on 2013-05-29
Changed in cinder:
milestone: none → havana-1
status: Fix Committed → Fix Released
tags: removed: grizzly-backport-potential
Thierry Carrez (ttx) on 2013-10-17
Changed in cinder:
milestone: havana-1 → 2013.2
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers