Setting v2 to true and v1 to false causes HTTPMultipleChoice error
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Glance |
Invalid
|
Undecided
|
Unassigned |
Bug Description
I have a question. When I have:
glance:
glance:
I get error:
HTTPMultipleChoices (HTTP 300) Requested version of OpenStack Images API is not available.
stack_status | CREATE_FAILED
stack_status_reason | Resource CREATE failed: HTTPMultipleCho
parameters | OS::project_id: 2713f28e0d0e481
| OS::stack_id: c4954b03-
| OS::stack_name: blah
|
outputs | []
The following link suggests heat still uses v1 - http://
When I change it to:
glance:
glance:
I get the error:
500 Internal Server Error: The server has either erred or is incapable of performing the requested operation. (HTTP 500)
We see this in the glance-api.log shortly after:
Constructed URL: http://
dir=asc&limit=20 _construct_url /usr/lib/
9191 is the port for the registry and not the api. The service is obviously disabled / not running per this pull request. How can that be?
create_image.yml : https:/
stack trace: https:/
About the 300: with v1 not enabled, any requests to v1 will return a 300 response. I don't know exactly what heat is doing under the hood, but if heat is trying to use v1 to make that create image request, you should see this in the glance-api log:
Jan 17 13:01:55 br-virtual-machine <email address hidden>[10751]: DEBUG glance. api.middleware. version_ negotiation [-] Determining version of request: POST /v1/images Accept: */* {{(pid=10753) process_request /opt/stack/ glance/ glance/ api/middleware/ version_ negotiation. py:45}} api.middleware. version_ negotiation [-] Using url versioning {{(pid=10753) process_request /opt/stack/ glance/ glance/ api/middleware/ version_ negotiation. py:57}} api.middleware. version_ negotiation [-] Unknown version. Returning version choices. {{(pid=10753) process_request /opt/stack/ glance/ glance/ api/middleware/ version_ negotiation. py:64}}
Jan 17 13:01:55 br-virtual-machine <email address hidden>[10751]: DEBUG glance.
Jan 17 13:01:55 br-virtual-machine <email address hidden>[10751]: DEBUG glance.
Jan 17 13:01:55 br-virtual-machine <email address hidden>[10751]: [pid: 10753|app: 0|req: 2/3] 127.0.0.1 () {40 vars in 770 bytes} [Wed Jan 17 13:01:55 2018] POST /v1/images => generated 678 bytes in 1 msecs (HTTP/1.1 300) 3 headers in 105 bytes (1 switches on core 0)
... and I just realized that these are all DEBUG level messages, so whether you'll see them or not depends on how the glance log levels are set.