-
Notifications
You must be signed in to change notification settings - Fork 407
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
Adds Native Image Support #842 #901
base: main
Are you sure you want to change the base?
Conversation
Oh nice - thank you. |
Codecov Report
@@ Coverage Diff @@
## main #901 +/- ##
=========================================
Coverage 71.52% 71.52%
Complexity 1345 1345
=========================================
Files 173 173
Lines 4984 4984
Branches 518 518
=========================================
Hits 3565 3565
Misses 1167 1167
Partials 252 252 Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
Hello @brenuart , I used @msailes Gist to generate a I recommend that this is properly tested and checked if i did not miss anything. So far i was able to get this working with Micronaut + GraalVM |
For anyone following this PR,... at present, we (the maintainers of logstash-logback-encoder) don't know how to generate, maintain, or test this file, so we cannot accept this PR as-is. Note the link to the gist mentioned in an earlier comment no longer works. If the PR were to be enhanced with an automated way to keep the file up-to-date (perhaps as part of the build process) and tests, then we would be more willing to accept it. |
You could use annotations in the code. But that would imply importing libraries and annotating classes |
What annotations? what libraries? What needs to be annotated? How do we test it with automation? Keep in mind I've never used GraalVM before, so explain it to me like a noob ;) |
I can't say for sure what script the original commenter used since the gist link is broken, but graalvm jdk provides an agent for automatically generating the reflection config as well as config files for JNI, proxy objects and class path resources. https://www.graalvm.org/22.0/reference-manual/native-image/Agent/ Essentially you build a fat jar from your application and run it with the graalvm jdk using the tracing agent java -agentlib:native-image-agent=config-output-dir=generated-configs -jar app.jar and the specified The annotation approach is what some frameworks e.g. quarkus and helidon are using to provide ways to annotate the classes that are using reflection. |
GraalVM Support