Improved GraalVM Support #710
-
Hello, When using this library 7.5.0 and building it as an GraalVM native-image, the current implementation which leverages log4j is really not desired due to the amount of reflection and configuration needed. Is there any plans to change and maybe use slf4j / logback instead for better support? For example, when creating a project you currently need the following two dependencies implementation("nl.basjes.parse.useragent:yauaa:7.5.0") After you have scanned and created your normal reflect-config, resource-config etc. You need to --initialize-at-build-time for all log4j classes that are used. Below example is required configuration with GraalVM 22.2.0
|
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 5 replies
-
Thanks for your input. Also to show how to use a different logging implementation I have added https://github.com/nielsbasjes/yauaa/tree/main/analyzer/src/it/Examples/java-slf4j I apparently have missed something for Quarkus. I'm going to need to do some experiments to understand your input. Do you have your test somewhere that I can have a look at it? |
Beta Was this translation helpful? Give feedback.
-
@JouperCoding https://github.com/nielsbasjes/yauaa/blob/main/analyzer/src/it/Examples/quarkus/ If I run the integration tests (normal build) it puts all the versions in th pom.xml and stores it in the In there I can now do It also creates a docker image that runs the same native image. It is not perfect yet because the native integration tests do not yet work (resource loading issue). |
Beta Was this translation helpful? Give feedback.
Thanks for your input.
Exactly to make sure it works with Quarkus I included this: https://github.com/nielsbasjes/yauaa/tree/main/analyzer/src/it/Examples/quarkus
Also to show how to use a different logging implementation I have added https://github.com/nielsbasjes/yauaa/tree/main/analyzer/src/it/Examples/java-slf4j
I apparently have missed something for Quarkus. I'm going to need to do some experiments to understand your input.
Do you have your test somewhere that I can have a look at it?