Skip to content

Conversation

@rsafonseca
Copy link
Contributor

VmwareStorageManagerImpl.java:1023, RCN_REDUNDANT_NULLCHECK_OF_NONNULL_VALUE, Priority: High
Redundant nullcheck of datastoreVolumePath, which is known to be non-null in com.cloud.hypervisor.vmware.manager.VmwareStorageManagerImpl.getVolumePathInDatastore(DatastoreMO, String)

Assertion is not used in runtime, correct way is throw and handle exception.
This just gets rid of the warning on the findbugs reports.

VmwareStorageManagerImpl.java:1023, RCN_REDUNDANT_NULLCHECK_OF_NONNULL_VALUE, Priority: High
Redundant nullcheck of datastoreVolumePath, which is known to be non-null in com.cloud.hypervisor.vmware.manager.VmwareStorageManagerImpl.getVolumePathInDatastore(DatastoreMO, String)

Assertion is not used in runtime, correct way is throw and handle exception without killing app
@asfbot
Copy link

asfbot commented Jun 7, 2015

cloudstack-pull-requests #315 SUCCESS
This pull request looks good

@DaanHoogland
Copy link
Contributor

I don't trust findbugs on this one. It seems to me searchFileInSubFolders() can return null.

@asfgit asfgit closed this in e8c7069 Jun 8, 2015
@DaanHoogland
Copy link
Contributor

accidentally closed anyway, doesn't hurt us immediately.

rohityadavcloud pushed a commit that referenced this pull request Jan 20, 2021
Fixes #362

Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com>
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
shwstppr pushed a commit to shapeblue/cloudstack that referenced this pull request Apr 11, 2024
…ues (apache#362)

* Introduced a new API "checkVolumeAndRepair" that allows users or admins to check and repair if any leaks observed.
Currently this is supported only for KVM

* some fixes

* Added unit tests

* addressed review comments

* add repair volume while granting access

* Changed repair parameter to accept both leaks/all values

* Introduced new global setting volume.check.and.repair.before.use to do volume check and repair before VM start or volume attach operations

* Added volume check and repair changes only during VM start and volume attach operations

* Refactored the names to look similar  across the code

* Some code fixes

* remove unused code

* Renamed repair values

* Addressed review comments

* code refactored

* used volume name in logs

* Changed the API to Async and the setting scope to storage pool

* Fixed exit value handling with check volume command

* Fixed storage scope to the setting

* Fixed volume format issues

* Refactored the log messages

* Fix formatting
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants