jamesfredley opened a new pull request, #1209:
URL: https://github.com/apache/grails-spring-security/pull/1209

   ## Summary
   
   - Add `<classifier>jakarta</classifier>` to the ehcache dependency in 
published POMs via `pom.withXml` customization
   - The existing `requireCapability('org.ehcache:ehcache-jakarta')` already 
works for Gradle consumers via `.module` metadata, but the POM lacked the 
classifier
   
   ## Problem
   
   The published POM for `grails-spring-security` 7.0.1 declares:
   
   ```xml
   <dependency>
     <groupId>org.ehcache</groupId>
     <artifactId>ehcache</artifactId>
     <scope>runtime</scope>
     <version>3.10.9</version>
     <!-- no classifier! -->
   </dependency>
   ```
   
   This causes `NoClassDefFoundError: javax/xml/bind/JAXBException` for 
consumers that resolve through the POM (Maven users, older Gradle, or Gradle 
with module metadata disabled).
   
   ## Fix
   
   The `.module` metadata already correctly declares `requestedCapabilities` 
for `ehcache-jakarta`. This PR adds a `pom.withXml` block to also inject the 
`jakarta` classifier into the generated POM, so both resolution paths work:
   
   - **Gradle consumers** (module metadata) - `requestedCapabilities` resolves 
jakarta variant ✅ (already working)
   - **Maven/POM consumers** - `<classifier>jakarta</classifier>` resolves 
jakarta variant ✅ (this fix)
   
   ## Verification
   
   Generated POM now contains:
   ```xml
   <groupId>org.ehcache</groupId>
   <artifactId>ehcache</artifactId>
   <scope>runtime</scope>
   <version>3.10.9</version>
   <classifier>jakarta</classifier>
   ```
   
   Fixes #1208
   Related: #1191


-- 
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