guru-bharadwaj20 opened a new pull request, #4510:
URL: https://github.com/apache/logging-log4j2/pull/4510

   Ports #3450 to `main`, as asked in #3600.
   
   The annotation libraries that `log4j-parent` declares with `provided` scope 
(bnd, Error Prone, JSpecify, OSGi bundle and versioning, SpotBugs) are now:
   
   - added as `compileOnlyApi` dependencies in the Gradle Module Metadata, 
through `gradle-module-metadata-maven-plugin`
   - listed in `bnd-jpms-module-info`, so bnd writes `requires static` for them 
in the generated `module-info`
   
   I used the current 2.x version of the change, with plugin version 1.2. 
Unlike 2.x, `main` still depends on `spotbugs-annotations`, so it stays in both 
lists, as it was in the original #3450. JSpecify isn't in the module list 
because bnd already emits `requires static org.jspecify` on `main`.
   
   What I checked, building `log4j-core` with `./mvnw -pl log4j-core -am 
install -DskipTests`:
   
   - `module-info.class` of `log4j-core` now has `requires static` for 
`biz.aQute.bnd.annotation`, `com.github.spotbugs.annotations`, 
`com.google.errorprone.annotations`, `org.osgi.annotation.bundle` and 
`org.osgi.annotation.versioning`. A build of `main` without the change has none 
of them.
   - The generated `log4j-core-3.0.0-SNAPSHOT.module` lists the six libraries 
in `apiElements` and not in `runtimeElements`.
   - `./mvnw -pl log4j-parent,log4j-core spotless:check` and `./mvnw -pl 
log4j-core -am verify -DskipTests` pass.
   
   Added a changelog entry in `src/changelog/.3.x.x`.
   
   Fixes #3600
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to