cinder assigns default volume_type even when it shouldn't
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Cinder |
Fix Released
|
High
|
Brian Rosmaita | ||
Train |
Fix Released
|
High
|
Brian Rosmaita | ||
Ussuri |
Fix Released
|
High
|
Brian Rosmaita | ||
Victoria |
Fix Released
|
High
|
Brian Rosmaita |
Bug Description
NOTE: the original bug report was about 'cinder_
When the 'cinder_
This is a regression from Change I4da0c13b5b3f81
It happens here at the REST API layer:
[0] https:/
(that's from v3, but the same code is in v2)
The change was part of an effort to eliminate untyped volumes in Cinder. The problem is that it sets a volume_type too soon (probably so that the volume_type element in the API response wouldn't be null. But as a result, it bypasses the selection code in the cinder-volume service [1], which would infer the volume_type based on source volume type, snapshot volume type, or image volume type. So basically, unless a user explicitly sets a volume_type in the original API request, that user is going to wind up with the default type.
I think the way to fix this is to (roughly) move the code from [0] into [1]. We could just document that the volume_type can be null in the API response while a volume is still building.
Change I4da0c13b5b3f81
summary: |
- cinder_img_volume_type no longer works + cinder assigns default volume_type even when it shouldn't |
description: | updated |
Fix proposed to branch: master /review. opendev. org/730183
Review: https:/