slavkap commented on code in PR #8755:
URL: https://github.com/apache/cloudstack/pull/8755#discussion_r1517560000
##########
server/src/main/java/com/cloud/storage/VolumeApiServiceImpl.java:
##########
@@ -2324,7 +2339,7 @@ private void validateVolumeResizeWithSize(VolumeVO
volume, long currentSize, Lon
* the actual disk size.
*/
if (currentSize > newSize) {
- if (volume != null &&
ImageFormat.QCOW2.equals(volume.getFormat()) &&
!Volume.State.Allocated.equals(volume.getState())) {
+ if (volume != null &&
ImageFormat.QCOW2.equals(volume.getFormat()) &&
!Volume.State.Allocated.equals(volume.getState()) &&
!StoragePoolType.StorPool.equals(volume.getPoolType())) {
Review Comment:
@sureshanaparti, there are a lot similar checks in the code
https://github.com/apache/cloudstack/blob/6dc3d06037c39019f29686281856443c37a3e6c0/server/src/main/java/com/cloud/storage/VolumeApiServiceImpl.java#L3229
I think there is no need to complicate the code by adding additional method
in the storage drivers
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]