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 missing uses declarations in module descriptor #3254

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

ppkarwasz
Copy link
Contributor

@ppkarwasz ppkarwasz commented Nov 29, 2024

All ServiceLoader.load() calls need a uses clause in the JPMS module descriptor. This PR:

  • Adds the missing @ServiceConsumer annotation to CoreDefaultBundle.
  • To simplify code review, it places @ServiceConsumer on each class (even a test case) that makes a ServiceLoader.load call and only those classes.

Fixes #3250

Since we don't have JPMS tests in the main repo, this PR is blocked by apache/logging-log4j-samples#231

All `ServiceLoader.load()` calls need a `uses` clause in the JPMS module descriptor.
This PR:

- Adds the missing `@ServiceConsumer` annotation to `CoreDefaultBundle`.
- To simplify code review, it places `@ServiceConsumer` on each class that makes a `ServiceLoader.load` call and only those classes.

Closes #3250
@ppkarwasz ppkarwasz self-assigned this Dec 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant