add same volume to the group-update does not show proper error

Bug #1946618 reported by shireesha bendi
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Cinder
Incomplete
Low
Unassigned

Bug Description

Add/Remove volumes (group-update) from the group does not show proper error or log messages.
When list of volumes are given to add them to the group, if a volume is already exists in the group
then it just silently removes the volumes from the list to be added (add_volumes_list) to the group.
Instead, it would be good to print a message in logs that the given volume already exists hence
the add volume operation for this volume is not required or something similar.

The below error message is printed which is of irrelevant for the problem. This seems to be a generic
message/error shown for most of the failure for this command.
cinder --os-volume-api-version 3.47 group-update --add-volumes b86017f8-a739-4055-a71b-fcc74bdd7f2c mytestgr123
ERROR: Invalid Group: Cannot update group 362b18bd-860b-444b-b9be-670d7de44daa because no valid name, description, add_volumes, or remove_volumes were provided. (HTTP 400) (Request-ID: req-97910a2a-9bd6-4113-b56b-be7f3623e6c0)

group/api.py, add a log info or warning message _validate_add_volumes while removing from the add_volumes_list.

Revision history for this message
Sofia Enriquez (lsofia-enriquez) wrote :

Greetings shireesha bendi,
do you mind sharing the next information:
- Cinder version
- Cinder Backend
Thanks in advance,
Sofia

Changed in cinder:
importance: Undecided → Wishlist
importance: Wishlist → Low
tags: added: group-update groups volume-groups
Changed in cinder:
status: New → Incomplete
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to cinder (master)

Fix proposed to branch: master
Review: https://review.opendev.org/c/openstack/cinder/+/817514

Changed in cinder:
status: Incomplete → In Progress
Revision history for this message
Brian Rosmaita (brian-rosmaita) wrote :

The title and description of this bug need to be revised. I think the actual bug is that if you make a group-update request that contains only volumes that are already in the group (and nothing else, no description or name updates), you get a 400 instead of a 2xx response.

Changed in cinder:
status: In Progress → Incomplete
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.