Hi,
This issue is not related to the barcode generation itself, but to a missing dependency in the cloud environment.
The key error is:
NoClassDefFoundError: Could not initialize class com.amazonaws.services.s3.internal.Constants
This indicates that required AWS SDK classes are not available at runtime in the Mendix cloud, even though it works locally.
Your AthenaJDBC42-2.2.2.1000.jar depends on AWS SDK libraries, but those dependencies are either:
/userlib, orLocally, your IDE may be resolving them implicitly, but in the cloud only /userlib is used.
1. Add missing AWS dependencies explicitly
Download and place the required AWS SDK JARs into /userlib, for example:
aws-java-sdk-coreaws-java-sdk-s3aws-java-sdk-athena (if required)Make sure versions are compatible with your Athena JDBC driver.
2. Avoid version conflicts
Mendix runtime already includes some AWS libraries. If versions mismatch, you can get this exact error.
To fix:
/userlib3. Re-deploy cleanly
4. Verify in logs
After deployment, confirm:
NoClassDefFoundErrorClassNotFoundException for AWS classesThe error appears at:
Core.storeFileDocumentContent(...)
but that is only where the failure surfaces. The actual issue happens earlier when the AWS-dependent class is initialized.
This is a classic dependency/classpath issue in Mendix cloud. Ensuring all required AWS SDK JARs are present and version-aligned in /userlib resolves the problem reliably.
Hi Anja,
Mendix always includes the AWS SDK, having these S3 jars, even if they are not present in the userlib or vendorlib folders, because S3 is natively used for file storage.
As of version 10.24.14, Mendix upgraded to a newer version of this SDK (see Mendix docs). Please check for which version the Java Action was written and which version you are currently running your Mendix app.
If that doesn't seem to be the cause, please also confirm the origin of the action (self-build?) and the cloud you're hosting (Mendix cloud?).
Kind regards,
Johan
Hi Anja Sperling
You are missing one or more AWS SDK dependencies in your userlib when deployed to the cloud.
Athena JDBC drivers are not fully self-contained they rely on external AWS libraries unless you use a bundled version. The best way is to use the Athena with-dependencies driver so that it will come with all the jar it needs. If all jars are there properly cross check whether those jar are include in the project and there in userlib.
And more over check for any duplicate jars in userlib
aws-java-sdk-*.jar
aws-java-sdk-s3-*.jar
httpclient-*.jar
jackson-*.jar
I hope this helps