CLVM enhancements and fixes #12617
CLVM enhancements and fixes #12617
Quality Gate failed
Failed conditions
1 Security Hotspot
33.1% Coverage on New Code (required ≥ 40%)
Annotations
sonarqubecloud / SonarCloud Code Analysis
Format specifiers should be used instead of string concatenation.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig9XULLXNfHHEi1hl&open=AZ4Ig9XULLXNfHHEi1hl&pullRequest=12617
sonarqubecloud / SonarCloud Code Analysis
Remove this and every subsequent useless "eq(...)" invocation; pass the values directly.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig9K5LLXNfHHEi1ga&open=AZ4Ig9K5LLXNfHHEi1ga&pullRequest=12617
sonarqubecloud / SonarCloud Code Analysis
Remove this field injection and use constructor injection instead.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig83DLLXNfHHEi1f0&open=AZ4Ig83DLLXNfHHEi1f0&pullRequest=12617
sonarqubecloud / SonarCloud Code Analysis
Remove the declaration of thrown exception 'org.libvirt.LibvirtException', as it cannot be thrown from method's body.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig9XgLLXNfHHEi1hu&open=AZ4Ig9XgLLXNfHHEi1hu&pullRequest=12617
sonarqubecloud / SonarCloud Code Analysis
Extract this nested try block into a separate method.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig9UJLLXNfHHEi1hV&open=AZ4Ig9UJLLXNfHHEi1hV&pullRequest=12617
sonarqubecloud / SonarCloud Code Analysis
Rename this field "_volDetailsDao" to match the regular expression '^[a-z][a-zA-Z0-9]*$'.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig83DLLXNfHHEi1fx&open=AZ4Ig83DLLXNfHHEi1fx&pullRequest=12617
sonarqubecloud / SonarCloud Code Analysis
Add at least one assertion to this test case.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig9bNLLXNfHHEi1iT&open=AZ4Ig9bNLLXNfHHEi1iT&pullRequest=12617
Check warning on line 5025 in server/src/main/java/com/cloud/storage/VolumeApiServiceImpl.java
sonarqubecloud / SonarCloud Code Analysis
A "Brain Method" was detected. Refactor it to reduce at least one of the following metrics: LOC from 170 to 64, Complexity from 47 to 14, Nesting Level from 4 to 2, Number of Variables from 31 to 6.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig9hlLLXNfHHEi1jD&open=AZ4Ig9hlLLXNfHHEi1jD&pullRequest=12617
sonarqubecloud / SonarCloud Code Analysis
Remove this field injection and use constructor injection instead.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig83DLLXNfHHEi1fy&open=AZ4Ig83DLLXNfHHEi1fy&pullRequest=12617
sonarqubecloud / SonarCloud Code Analysis
Merge this if statement with the enclosing one.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig8_7LLXNfHHEi1gA&open=AZ4Ig8_7LLXNfHHEi1gA&pullRequest=12617
sonarqubecloud / SonarCloud Code Analysis
Remove this and every subsequent useless "eq(...)" invocation; pass the values directly.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig9AzLLXNfHHEi1gI&open=AZ4Ig9AzLLXNfHHEi1gI&pullRequest=12617
sonarqubecloud / SonarCloud Code Analysis
Define a constant instead of duplicating this literal "/dev/" 10 times.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig9SkLLXNfHHEi1g0&open=AZ4Ig9SkLLXNfHHEi1g0&pullRequest=12617
sonarqubecloud / SonarCloud Code Analysis
Refactor this method to reduce its Cognitive Complexity from 22 to the 15 allowed.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig9UJLLXNfHHEi1hf&open=AZ4Ig9UJLLXNfHHEi1hf&pullRequest=12617
sonarqubecloud / SonarCloud Code Analysis
Extract this nested ternary operation into an independent statement.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig9SkLLXNfHHEi1g_&open=AZ4Ig9SkLLXNfHHEi1g_&pullRequest=12617
Check warning on line 378 in server/src/main/java/com/cloud/storage/VolumeApiServiceImpl.java
sonarqubecloud / SonarCloud Code Analysis
Remove this field injection and use constructor injection instead.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig9hlLLXNfHHEi1i-&open=AZ4Ig9hlLLXNfHHEi1i-&pullRequest=12617
sonarqubecloud / SonarCloud Code Analysis
Format specifiers should be used instead of string concatenation.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig9XULLXNfHHEi1hm&open=AZ4Ig9XULLXNfHHEi1hm&pullRequest=12617
sonarqubecloud / SonarCloud Code Analysis
Add at least one assertion to this test case.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig9bNLLXNfHHEi1ic&open=AZ4Ig9bNLLXNfHHEi1ic&pullRequest=12617
Check warning on line 80 in server/src/main/java/com/cloud/storage/clvm/ClvmPoolManager.java
sonarqubecloud / SonarCloud Code Analysis
Add the missing @Deprecated annotation.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig9f_LLXNfHHEi1iz&open=AZ4Ig9f_LLXNfHHEi1iz&pullRequest=12617
sonarqubecloud / SonarCloud Code Analysis
Remove this and every subsequent useless "eq(...)" invocation; pass the values directly.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig9K5LLXNfHHEi1gb&open=AZ4Ig9K5LLXNfHHEi1gb&pullRequest=12617
sonarqubecloud / SonarCloud Code Analysis
Remove this use of "Script"; it is deprecated.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig9SkLLXNfHHEi1hA&open=AZ4Ig9SkLLXNfHHEi1hA&pullRequest=12617
sonarqubecloud / SonarCloud Code Analysis
Refactor this method to reduce its Cognitive Complexity from 19 to the 15 allowed.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig9UJLLXNfHHEi1he&open=AZ4Ig9UJLLXNfHHEi1he&pullRequest=12617
sonarqubecloud / SonarCloud Code Analysis
Update this method so that its implementation is not identical to "testSelectObject_CLVMVolumeWithInvalidLockHostId" on line 476.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig87pLLXNfHHEi1f5&open=AZ4Ig87pLLXNfHHEi1f5&pullRequest=12617
sonarqubecloud / SonarCloud Code Analysis
Remove this use of "Script"; it is deprecated.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig9NWLLXNfHHEi1gi&open=AZ4Ig9NWLLXNfHHEi1gi&pullRequest=12617
Check warning on line 30 in core/src/main/java/com/cloud/agent/api/PostMigrationCommand.java
sonarqubecloud / SonarCloud Code Analysis
Override the "equals" method in this class.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig9MKLLXNfHHEi1gd&open=AZ4Ig9MKLLXNfHHEi1gd&pullRequest=12617
Check failure on line 310 in server/src/main/java/com/cloud/storage/clvm/ClvmPoolManager.java
sonarqubecloud / SonarCloud Code Analysis
Refactor this method to reduce its Cognitive Complexity from 20 to the 15 allowed.
See more on https://sonarcloud.io/project/issues?id=apache_cloudstack&issues=AZ4Ig9f_LLXNfHHEi1i7&open=AZ4Ig9f_LLXNfHHEi1i7&pullRequest=12617