DaanHoogland commented on code in PR #10775: URL: https://github.com/apache/cloudstack/pull/10775#discussion_r2058625039
########## plugins/storage/volume/storpool/src/main/java/org/apache/cloudstack/storage/datastore/driver/StorPoolPrimaryDataStoreDriver.java: ########## @@ -427,6 +428,18 @@ private String resizeVolume(DataObject data, String path, VolumeObject vol) { return err; } + private void updateVolumeWithTheNewSize(VolumeObject vol, ResizeVolumePayload payload) { + + vol.setSize(payload.newSize); + vol.update(); + if (payload.newMaxIops != null) { + VolumeVO volume = volumeDao.findById(vol.getId()); + volume.setMaxIops(payload.newMaxIops); + volumeDao.update(volume.getId(), volume); + } + updateStoragePool(vol.getPoolId(), payload.newSize - vol.getSize()); Review Comment: should this be transactional? (i.e. no update on the volume if it fails on the backend..) -- 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: commits-unsubscr...@cloudstack.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org