elharo opened a new pull request, #642:
URL: https://github.com/apache/maven-war-plugin/pull/642

   Fixes #522
   
   ## Problem
   When maven-dependency-plugin copies provided-scope JARs to `WEB-INF/lib/`, 
the WAR plugin's outdated-resource cleanup deletes them because they were not 
copied by the WAR plugin itself and their timestamps predate the session start 
time.
   
   ## Solution
   In `DefaultWarPackagingContext`, skip adding files under `WEB-INF/lib/` to 
`outdatedResources` unless they match an expected runtime-artifact filename. A 
new `getRuntimeArtifactFileNames()` method computes the expected filenames from 
the set of runtime-scope library artifacts, respecting `outputFileNameMapping` 
if configured.
   
   ## Changes
   - `AbstractWarMojo.java`: Added `getRuntimeArtifactFileNames()`; modified 
`FileVisitor` to skip marking non-artifact lib files as outdated.
   - `AbstractWarPackagingTask.java`: Extracted `isLibraryType()` for reuse.
   - `ArtifactsPackagingTask.java`: Refactored to use shared `isLibraryType()`.
   - `WarExplodedMojoTest.java`: Added regression test.


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