cloudstack
cloudstack copied to clipboard
Build: support JRE17 for building and sonar check
Description
This PR fixes the issue with sonar check
Error: Failed to execute goal org.sonarsource.scanner.maven:sonar-maven-plugin:3.9.1.2184:sonar (default-cli) on project cloudstack:
Error:
Error: The version of Java (11.0.22) used to run this analysis is deprecated, and SonarCloud no longer supports it. Please upgrade to Java 17 or later.
Error: You can find more information here: https://docs.sonarsource.com/sonarcloud/appendices/scanner-environment/
Types of changes
- [ ] Breaking change (fix or feature that would cause existing functionality to change)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Bug fix (non-breaking change which fixes an issue)
- [ ] Enhancement (improves an existing feature and functionality)
- [ ] Cleanup (Code refactoring and cleanup, that may add test cases)
- [x] build/CI
Feature/Enhancement Scale or Bug Severity
Feature/Enhancement Scale
- [ ] Major
- [ ] Minor
Bug Severity
- [ ] BLOCKER
- [ ] Critical
- [ ] Major
- [ ] Minor
- [ ] Trivial
Screenshots (if appropriate):
How Has This Been Tested?
How did you try to break this feature and the system with this change?
Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 28.40%. Comparing base (
d5d8b6d) to head (b16d00a). Report is 106 commits behind head on main.
Additional details and impacted files
@@ Coverage Diff @@
## main #8609 +/- ##
============================================
- Coverage 30.82% 28.40% -2.42%
+ Complexity 34015 30942 -3073
============================================
Files 5344 5344
Lines 375411 375411
Branches 54572 54572
============================================
- Hits 115710 106646 -9064
- Misses 244434 254531 +10097
+ Partials 15267 14234 -1033
| Flag | Coverage Δ | |
|---|---|---|
| simulator-marvin-tests | 21.29% <ø> (-3.33%) |
:arrow_down: |
| uitests | 4.38% <ø> (ø) |
|
| unit-tests | 16.56% <ø> (+<0.01%) |
:arrow_up: |
Flags with carried forward coverage won't be shown. Click here to find out more.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Just discussed with @vishesh92
it requires lots of changes to support packaging cloudstack with jre17 cc @rohityadavcloud @DaanHoogland
This pull request has merge conflicts. Dear author, please fix the conflicts and sync your branch with the base branch.
Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 15.54%. Comparing base (
7214c13) to head (97be6a6). Report is 49 commits behind head on main.
Additional details and impacted files
@@ Coverage Diff @@
## main #8609 +/- ##
============================================
- Coverage 15.54% 15.54% -0.01%
- Complexity 11976 11977 +1
============================================
Files 5495 5495
Lines 481076 481076
Branches 60094 58769 -1325
============================================
- Hits 74780 74777 -3
- Misses 398033 398037 +4
+ Partials 8263 8262 -1
| Flag | Coverage Δ | |
|---|---|---|
| uitests | 4.21% <ø> (ø) |
|
| unittests | 16.30% <ø> (-0.01%) |
:arrow_down: |
Flags with carried forward coverage won't be shown. Click here to find out more.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
@blueorangutan package
@weizhouapache a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.
Packaging result [SF]: ✔️ el7 ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 9525
@blueorangutan package
@weizhouapache a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.
Packaging result [SF]: ✔️ el7 ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 9528
@blueorangutan test rocky8 kvm-rocky8
@weizhouapache a [SL] Trillian-Jenkins test job (rocky8 mgmt + kvm-rocky8) has been kicked to run smoke tests
[SF] Trillian test result (tid-10152) Environment: kvm-rocky8 (x2), Advanced Networking with Mgmt server r8 Total time taken: 50560 seconds Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr8609-t10152-kvm-rocky8.zip Smoke tests completed. 129 look OK, 2 have errors, 0 did not run Only failed and skipped tests results shown below:
| Test | Result | Time (s) | Test File |
|---|---|---|---|
| test_01_events_resource | Error |
423.78 | test_events_resource.py |
| test_01_restore_vm | Error |
0.23 | test_restore_vm.py |
| test_02_restore_vm_allocated_root | Error |
0.16 | test_restore_vm.py |
| ContextSuite context=TestRestoreVM>:teardown | Error |
1.25 | test_restore_vm.py |
@blueorangutan package
@vishesh92 a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.
Packaging result [SF]: ✔️ el7 ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 9587
@blueorangutan test matrix
@weizhouapache a [SL] Trillian-Jenkins matrix job (centos7 mgmt + xenserver71, rocky8 mgmt + vmware67u3, centos7 mgmt + kvmcentos7) has been kicked to run smoke tests
[SF] Trillian test result (tid-10200) Environment: xenserver-71 (x2), Advanced Networking with Mgmt server 7 Total time taken: 46762 seconds Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr8609-t10200-xenserver-71.zip Smoke tests completed. 130 look OK, 1 have errors, 0 did not run Only failed and skipped tests results shown below:
| Test | Result | Time (s) | Test File |
|---|---|---|---|
| test_01_events_resource | Error |
350.31 | test_events_resource.py |
[SF] Trillian test result (tid-10202) Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7 Total time taken: 53292 seconds Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr8609-t10202-kvm-centos7.zip Smoke tests completed. 128 look OK, 3 have errors, 0 did not run Only failed and skipped tests results shown below:
| Test | Result | Time (s) | Test File |
|---|---|---|---|
| test_01_events_resource | Error |
419.33 | test_events_resource.py |
| test_02_list_cpvm_vm | Failure |
0.04 | test_ssvm.py |
| test_04_cpvm_internals | Failure |
0.04 | test_ssvm.py |
| test_03_create_redundant_VPC_1tier_2VMs_2IPs_2PF_ACL_reboot_routers | Failure |
457.48 | test_vpc_redundant.py |
| test_05_rvpc_multi_tiers | Failure |
536.44 | test_vpc_redundant.py |
| test_05_rvpc_multi_tiers | Error |
536.45 | test_vpc_redundant.py |
[SF] Trillian test result (tid-10201) Environment: vmware-67u3 (x2), Advanced Networking with Mgmt server r8 Total time taken: 53477 seconds Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr8609-t10201-vmware-67u3.zip Smoke tests completed. 128 look OK, 3 have errors, 0 did not run Only failed and skipped tests results shown below:
| Test | Result | Time (s) | Test File |
|---|---|---|---|
| test_01_events_resource | Error |
341.42 | test_events_resource.py |
| test_02_balanced_drs_algorithm | Failure |
135.64 | test_cluster_drs.py |
| test_02_restore_vm_with_disk_offering | Error |
58.29 | test_restore_vm.py |
| test_03_restore_vm_with_disk_offering_custom_size | Error |
55.20 | test_restore_vm.py |
@weizhouapache Needs more changes, wrt:
- RPM & DEB packaging to depend on JRE17 packages
- Ensure both mgmt server, usage server and KVM agent can run against JRE17 in the CI/CD tests (i.e. changes in Trillian)
Worth also testing, these distro wrt JRE17:
- Ubuntu 22.04, 24.04
- Debian 12
- Oracle Linux 8, 9 (and or Alma Linux 8/9)
- openSUSE 15
- All supported hypervisors
@blueorangutan package
@rohityadavcloud a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.
@weizhouapache I see you haven't forced pom.xml to use the JDK17, fair to say this would make cloudstack codebase build/work with both JDK 11 and JDK17? In which case should we merge this? (I see smoketests are still using JRE17) cc @DaanHoogland @sureshanaparti @shwstppr
Packaging result [SF]: ✔️ el7 ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 9637
@weizhouapache I see you haven't forced pom.xml to use the JDK17, fair to say this would make cloudstack codebase build/work with both JDK 11 and JDK17? In which case should we merge this? (I see smoketests are still using JRE17) cc @DaanHoogland @sureshanaparti @shwstppr
@rohityadavcloud I will update
- all github actions to run with jdk17
- debian/control and cloud.spec to support packaging with jdk 11/17
We need to create new docker images for the packaging job on jenkins. This is optional. I suggest to package with jdk11 as old systemvm template still uses jre11
@blueorangutan package
@weizhouapache a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.
Packaging result [SF]: ✖️ el7 ✖️ el8 ✖️ el9 ✖️ debian ✖️ suse15. SL-JID 9646