Skip to content

CloudStack modernization: Java 17 + Jakarta + Phase 4 decomposition complete#1

Open
d4m14ndx wants to merge 649 commits into
mainfrom
modernize-2026
Open

CloudStack modernization: Java 17 + Jakarta + Phase 4 decomposition complete#1
d4m14ndx wants to merge 649 commits into
mainfrom
modernize-2026

Conversation

@d4m14ndx
Copy link
Copy Markdown
Owner

@d4m14ndx d4m14ndx commented May 16, 2026

Summary

Modernization fork of Apache CloudStack covering dead-code removal, dependency upgrades, Java 17 + Jakarta + Spring 6 migration, cloud-native operability, container/Helm packaging, and the Phase 4 god-class decomposition program.

Status at modernize-2026@cdcb59f40b: Phase 4 tracked god-class line-count closeout is complete. Every tracked Phase 4 target is now below the 3K stopping rule.

Phase Status

Phase 1 - Dead Code Removal

  • Removed discontinued/dead integrations and tooling from the fork baseline.
  • Removed insecure legacy auth modules and other dead surface area.

Phase 2 - Dependency Modernization

  • Upgraded major dependency families for Java 17, security, and build support.
  • Reworked abandoned or outdated libraries where the fork needed maintained replacements.

Phase 3 - Java 17, Jakarta, Spring 6

  • Migrated from Java 11 to Java 17.
  • Migrated Spring 5.3 to Spring 6.1 and Jetty 9.4 to Jetty 11.
  • Moved application EE imports from javax.* to jakarta.* while preserving Java SE packages.
  • Fixed migration breakage across Spring, Jetty websocket, WireMock, cglib, ESAPI, CXF, Groovy, and related tests.

Phase 4 - God-Class Decomposition And Operability

God-class decomposition is now below the 3K threshold for the tracked closeout list:

File Current size Status
UserVmManagerImpl 2,867 DONE
NfsSecondaryStorageResource 2,988 DONE
ApiResponseHelper 2,642 DONE
VirtualMachineManagerImpl (engine) 2,912 DONE
NetworkOrchestrator 2,999 DONE
StorageSystemDataMotionStrategy 2,968 DONE
KubernetesClusterManagerImpl 2,948 DONE
ConfigurationManagerImpl 2,701 DONE
QueryManagerImpl 2,955 DONE
NetworkServiceImpl 2,999 DONE
AccountManagerImpl 2,935 DONE

Decomposition pattern:

  • Extract coherent behavior from large Spring manager classes into focused services/components.
  • Keep public API contracts and test spy hooks stable where needed.
  • Verify each slice with focused unit tests before merging.
  • Preserve broad CloudStack support; this fork did not narrow hypervisor scope as part of Phase 4.

Operability and packaging work in this branch includes:

  • Health endpoints for liveness/readiness.
  • Prometheus metrics surface.
  • OpenTelemetry tracing hooks.
  • JSON logging support.
  • Docker, docker-compose, Helm, and fork CI workflow work.

Phase 5 - UI Rebuild And SSO

Phase 5a is already in the branch: Next.js scaffold, design system shell, route stubs, Dockerfile, and web CI workflow. Phase 5b remains next: Auth.js, Redis/session BFF, and Java-side createUserSessionToken API work.

Latest Verification

Recent focused gates from the Phase 4 closeout:

  • mvn -pl services/secondary-storage/server -Dtest=NfsPostUploadRequestValidationServiceTest,NfsSecondaryStorageResourceTest,NfsPostUploadServiceTest -Dsurefire.failIfNoSpecifiedTests=false test - 21 tests, 0 failures.
  • mvn -pl server -Dtest=UserVmManagerImplTest,VmAssignmentValidatorImplTest,VmAssignmentNetworkServiceImplTest,VmAssignmentOwnershipServiceImplTest -Dsurefire.failIfNoSpecifiedTests=false test - 180 tests, 0 failures.
  • Web workflow permissions cleanup added permissions: contents: read to .github/workflows/web.yml.

Before final upstream-facing merge/release, rerun the broader server/reactor and UI checks because this PR is intentionally a long-running modernization diff.

Docs

  • docs/AUDIT.md
  • docs/OBSERVABILITY.md
  • docs/DEVELOPMENT.md
  • docs/REFACTORING.md
  • docs/DEPLOYMENT.md
  • docs/PROGRESS.md

Remaining Follow-Up

  • Git/GitHub branch cleanup after preserving only useful long-lived branches.
  • Phase 5b implementation decisions and execution.
  • Broader full-suite verification after the cleanup pass.
  • Manual smoke tests for deployed health, metrics, JSON logging, tracing, and UI flows.

Comment thread .github/workflows/web.yml Fixed
Damian Guppy added 29 commits May 19, 2026 19:39
…stanceResponseService)

# Conflicts:
#	server/src/main/java/com/cloud/api/ApiResponseHelper.java
#	server/src/test/java/com/cloud/api/ApiResponseHelperTest.java
…DownloadCertificateResponseService)

# Conflicts:
#	server/src/main/java/com/cloud/api/ApiResponseHelper.java
#	server/src/test/java/com/cloud/api/ApiResponseHelperTest.java
Damian Guppy and others added 30 commits May 22, 2026 02:07
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.

2 participants