Cloud Manager build and deployment errors · updated
Cloud Manager build fails on the Java version: how to set Java 21, 17 or 11
Cloud Manager's build environment sets JAVA_HOME to Oracle JDK 8 by default, so a project that needs a newer Java fails with compiler or plugin errors unless you choose the version. Create a file named .cloudmanager/java-version in the branch the pipeline builds, containing only 21 or 17; Adobe prefers 21 for AEM Cloud Service projects.
What the build environment has
| Item | Value (Adobe's page, checked 10 Nov 2026) |
|---|---|
| Base image | Linux, derived from Ubuntu 22.04 |
| Maven | 3.9.4 |
| JDKs installed | Oracle JDK 11.0.22, 17.0.10 and 21.0.4 |
| Default JAVA_HOME | Oracle JDK 8u401 |
| Supported for Cloud Service projects | 21 (preferred), 17, 11 |
Adobe's page says the file should contain only the text 21 or 17. Cloud Manager also accepts 8, but that is no longer supported for AEM Cloud Service projects, and any other value is ignored.
Typical error signs
- 'invalid target release: 17' or 'release version 21 not supported' from the compiler plugin.
- A plugin compiled for a newer Java failing with UnsupportedClassVersionError.
- JaCoCo errors: the required jacoco-maven-plugin version depends on the project's Java version.
Moving to Java 21 safely
Adobe recommends running the local SDK on Java 21 first, then pointing a dev pipeline at a branch with the new java-version file, and only then stage and production. Check logs for class-loading or bytecode-weaving errors on the way.
.cloudmanager/java-version
21How to fix it
- Create .cloudmanager/java-version at the repository root of the pipeline's branch.
- Put only 21 (or 17) in it, no other text.
- Set maven.compiler.release in the POM to the same version.
- Update jacoco-maven-plugin to a version that supports that Java.
- Run a dev pipeline before stage and production.
Related pages on this site
Questions
Which Java does Cloud Manager use if I do nothing?
Oracle JDK 8, because JAVA_HOME defaults to jdk1.8.0_401 in the build environment.
Can I write 11 in the java-version file?
Adobe's page says to put 21 or 17 in the file; JDK 11 is installed and listed as an option for Cloud projects, so check the current page for how to select it.
Does the runtime Java change with the build Java?
No. The runtime is managed by Adobe; Java 21 runtime applies to eligible environments. Test on dev first.
Sources
- Adobe: Build environment of Cloud Manager (checked 10 Nov 2026)
Facts about Adobe's platform are from the linked Adobe pages, checked 10 Nov 2026. Explanations and examples are ours unless marked as Adobe's.