-
Notifications
You must be signed in to change notification settings - Fork 39
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
aws-crt-java causes an error when native compiled with graalvm #780
Labels
Comments
klopfdreh
added
bug
This issue is a bug.
needs-triage
This issue or PR still needs to be triaged.
labels
Apr 23, 2024
See also: aws/aws-sdk-java-v2#5127 |
jmklix
added
feature-request
A feature should be added or improved.
p2
This is a standard priority issue
and removed
needs-triage
This issue or PR still needs to be triaged.
bug
This issue is a bug.
labels
Apr 23, 2024
graalvm is currently not supported by the aws-crt-java. Changing this to a feature request |
Closed
Resolved via: #791 |
Closed as completed |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Describe the bug
Spring Boot Native build is not possible with aws-crt-java as there are many errors during the runtime.
Expected Behavior
Spring Boot Native build should run and use the JNI functionalities as it would run in a JVM.
Current Behavior
There are several issues during the runtime see solution.
Reproduction Steps
Perform a native-image build with GraalVM with Spring Boot 3.2.x.
Possible Solution
reflect-config.json
and add the following content[ { "name": "software.amazon.awssdk.crt.s3.S3Client", "methods": [ { "name": "<init>", "parameterTypes": [] } ] } ]
This is required during the native build
-H:ReflectionConfigurationResources=META-INF/.../reflect-config.json
resource-config.json
and add the following contentNote:
...
means for each so-file.This is require during the native build
-H:ResourceConfigurationResources=META-INF/.../resource-config.json
jni-config.json
for the JNI resources so that it can be applied like described here: https://www.graalvm.org/latest/reference-manual/native-image/dynamic-features/JNI/ and here https://docs.oracle.com/en/graalvm/enterprise/20/docs/reference-manual/native-image/JNI/#integration - alternatively apply the code as a custom FeatureAdditional Information/Context
I already tried to add the
reflect-config.json
and theresource-config.json
into the classpath and run the image but failed with the following error inside the container: container.logIs there any hint how to use AWS CRT with Spring Boot Native?
aws-crt-java version used
v0.29.18
Java version used
jdk17.0.10
Operating System and version
linux / ubi9-minimal:9.3-1612
The text was updated successfully, but these errors were encountered: