Loading

Mule Build/Deploy Fails with EnumConstantNotPresentException: JavaVersion.JAVA_25 Using Salesforce Connector 12.0.1 or MUnit 3.7.3

Publiseringsdato: Aug 26, 2026
Beskrivelse
Building or deploying a Mule 4 application fails with java.lang.EnumConstantNotPresentException: org.mule.sdk.api.meta.JavaVersion.JAVA_25 when either Salesforce Connector 12.0.1 or MUnit 3.7.3 is used with Mule Runtime versions earlier than 4.9.11 (Salesforce Connector) or 4.9.9 (MUnit compatibility gap). Both components declare support for JAVA_25 via the @JavaVersionSupport annotation, but the mule-sdk-api JAR bundled with older runtimes doesn't define that enum constant, so the Mule Maven Plugin's process-classes phase throws a ToolingException and aborts the build before tests or deployment can run.
 
Steps to Reproduce
  1. Set up a Mule project with: Mule Runtime 4.9.0, Maven 3.9.6, OpenJDK 17.
  2. Add Salesforce Connector 12.0.1 and/or MUnit 3.7.3 to the project's parent POM.
  3. Run mvn clean install from the terminal.
  4. Observe the build failing during the MUnit application deployment/build phase.
Observed behavior: Build fails with EnumConstantNotPresentException: org.mule.sdk.api.meta.JavaVersion.JAVA_25, aborting before any test or deployment step.
 
Expected behavior: The application should build and deploy successfully, as documented in the respective release notes.
 
Error Message
java.lang.EnumConstantNotPresentException: org.mule.sdk.api.meta.JavaVersion.JAVA_25 at java.base/sun.reflect.annotation.EnumConstantNotPresentExceptionProxy.generateException at java.base/sun.reflect.annotation.AnnotationInvocationHandler.invoke at org.mule.runtime...JavaExtensionModelParser.parseSupportedJavaVersions at org.mule.tools.maven.mojo.ProcessClassesMojo.doExecute
Løsning
  1. Upgrade Mule Runtime to 4.9.11 or later (resolves the Salesforce Connector 12.0.1 incompatibility) — confirmed working via Anypoint Studio's embedded 4.9.11 runtime.
  2. If staying on an older runtime (e.g., 4.9.0), downgrade to Salesforce Connector 12.0.0 and MUnit 3.7.1, which build successfully together.
  3. MUnit 3.7.3 specifically requires Mule Runtime 4.9.9 or later.
  4. Upgrade Mule Maven Plugin version to 4.10.1
Knowledge-artikkelnummer

005391109

 
Laster
Salesforce Help | Article