VMAX: Address nits in list manageable code
This addresses nits pointed out during review of list manageable volumes and snapshots in https://review.openstack.org/#/c/557297/ Change-Id: I77d95bc2f9385151e76c23f17810260df96d6868
This commit is contained in:
parent
d05a7a10dc
commit
cea466cfe0
@ -2153,7 +2153,7 @@ class VMAXCommon(object):
|
|||||||
:param offset: Number of volumes to skip after marker. Default=None.
|
:param offset: Number of volumes to skip after marker. Default=None.
|
||||||
:param sort_keys: Key to sort by, sort by size or reference. Valid
|
:param sort_keys: Key to sort by, sort by size or reference. Valid
|
||||||
keys: size, reference. Default=None.
|
keys: size, reference. Default=None.
|
||||||
:param sort_dirs: Direction to sort by. Valid dirs: asd, desc.
|
:param sort_dirs: Direction to sort by. Valid dirs: asc, desc.
|
||||||
Default=None.
|
Default=None.
|
||||||
:return: List of dicts containing all volumes valid for management
|
:return: List of dicts containing all volumes valid for management
|
||||||
"""
|
"""
|
||||||
@ -2166,9 +2166,9 @@ class VMAXCommon(object):
|
|||||||
|
|
||||||
# No volumes returned from VMAX
|
# No volumes returned from VMAX
|
||||||
if not volumes:
|
if not volumes:
|
||||||
LOG.warning("There were no volumes found on the backend VMAX. "
|
LOG.info("There were no volumes found on the backend VMAX. "
|
||||||
"You need to create some volumes before they can be "
|
"You need to create some volumes before they can be "
|
||||||
"managed into Cinder.")
|
"managed into Cinder.")
|
||||||
return manageable_vols
|
return manageable_vols
|
||||||
|
|
||||||
for device in volumes:
|
for device in volumes:
|
||||||
@ -2188,7 +2188,7 @@ class VMAXCommon(object):
|
|||||||
manageable_vols.append(volume_dict)
|
manageable_vols.append(volume_dict)
|
||||||
|
|
||||||
# If volume list is populated, perform filtering on user params
|
# If volume list is populated, perform filtering on user params
|
||||||
if len(manageable_vols) > 0:
|
if manageable_vols:
|
||||||
# If sort keys selected, determine if by size or reference, and
|
# If sort keys selected, determine if by size or reference, and
|
||||||
# direction of sort
|
# direction of sort
|
||||||
if sort_keys:
|
if sort_keys:
|
||||||
@ -2238,7 +2238,7 @@ class VMAXCommon(object):
|
|||||||
:param offset: Number of volumes to skip after marker. Default=None.
|
:param offset: Number of volumes to skip after marker. Default=None.
|
||||||
:param sort_keys: Key to sort by, sort by size or reference.
|
:param sort_keys: Key to sort by, sort by size or reference.
|
||||||
Valid keys: size, reference. Default=None.
|
Valid keys: size, reference. Default=None.
|
||||||
:param sort_dirs: Direction to sort by. Valid dirs: asd, desc.
|
:param sort_dirs: Direction to sort by. Valid dirs: asc, desc.
|
||||||
Default=None.
|
Default=None.
|
||||||
:return: List of dicts containing all volumes valid for management
|
:return: List of dicts containing all volumes valid for management
|
||||||
"""
|
"""
|
||||||
@ -2250,9 +2250,9 @@ class VMAXCommon(object):
|
|||||||
|
|
||||||
# No volumes returned from VMAX
|
# No volumes returned from VMAX
|
||||||
if not volumes:
|
if not volumes:
|
||||||
LOG.warning("There were no volumes found on the backend VMAX. "
|
LOG.info("There were no volumes found on the backend VMAX. "
|
||||||
"You need to create some volumes before snapshots can "
|
"You need to create some volumes before snapshots can "
|
||||||
"be created and managed into Cinder.")
|
"be created and managed into Cinder.")
|
||||||
return manageable_snaps
|
return manageable_snaps
|
||||||
|
|
||||||
for device in volumes:
|
for device in volumes:
|
||||||
|
Loading…
Reference in New Issue
Block a user