AlexanderBartash opened a new pull request, #2319: URL: https://github.com/apache/maven-resolver/pull/2319
On Windows the final move of a collocated temp file falls back to a stream copy in two cases: all rename attempts are refused because another process holds the target open, or the file system does not support an atomic move and the file is staged next to the target first. The copy left the target with the current time, so the time that the transport had set on the temp file from the remote "Last-Modified" was lost. A rename keeps it. classicCopy now sets the last modified time of the target to that of the source, so the local repository holds the same time whichever way the file reaches its place. The time is set on a best-effort basis: the fallback exists to let the build complete, so it does not fail when only the time cannot be set. This is the 2.x part of #2317; the 1.9.x line loses the time on every download on Windows and is fixed separately. Generated-by: Claude Code (claude-fable-5-2) --- To make clear that you license your contribution under the [Apache License Version 2.0, January 2004](https://www.apache.org/licenses/LICENSE-2.0) check one of the following: - [x] I hereby declare this contribution to be licensed under the [Apache License Version 2.0, January 2004](https://www.apache.org/licenses/LICENSE-2.0) - [x] I hereby declare that I have filed an [Apache Individual Contributor License Agreement](https://www.apache.org/licenses/icla.pdf). -- 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]
