Skip to content
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

Add reachability-metadata.json to all Log4j modules #3053

Merged
merged 6 commits into from
Oct 4, 2024

Conversation

ppkarwasz
Copy link
Contributor

This PR adds a plugin processor that generates a GraalVM reachability metadata file and bundles it with each Log4j module.

After this change, GraalVM will be able to handle Log4j Core without any user intervention.

Note: I also added a static resource-config.json file that specifies that all resources starting with log4j2 and the plugin descriptor must be included in the GraalVM image.

Part of #2831.

This PR adds a plugin processor that generates a GraalVM reachability metadata file and bundles it with each Log4j module.

After this change, GraalVM will be able to handle Log4j Core without any user intervention.

**Note**: I also added a static `resource-config.json` file that specifies that all resources starting with `log4j2` and the plugin descriptor must be included in the GraalVM image.
@vy vy added the graalvm Issue related to GraalVM support label Oct 3, 2024
@vy vy added this to the 2.25.0 milestone Oct 3, 2024
Copy link
Member

@vy vy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Slick implementation! 💯

Simplifies `ReachabilityMetadata` and fixes unclosed resource.
Add a GraalVM metadata file to include the following 3 files into an executable:

* `log4j2.component.properties`,
* `log4j2.simplelog.properties`,
* `log4j2.StatusLogger.properties`
@ppkarwasz ppkarwasz merged commit a14f0ad into 2.x Oct 4, 2024
9 checks passed
@ppkarwasz ppkarwasz deleted the feature/2.x/graalvm-processor branch October 4, 2024 08:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
graalvm Issue related to GraalVM support
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants