gnodet commented on code in PR #2137:
URL: https://github.com/apache/maven/pull/2137#discussion_r1979288676


##########
impl/maven-logging/src/main/java/org/apache/maven/slf4j/SimpleLoggerConfiguration.java:
##########
@@ -231,7 +231,7 @@ private static OutputChoice computeOutputChoice(String 
logFile, boolean cacheOut
             return new OutputChoice(cacheOutputStream ? 
OutputChoiceType.CACHED_SYS_OUT : OutputChoiceType.SYS_OUT);
         } else {
             try {
-                FileOutputStream fos = new FileOutputStream(logFile);
+                FileOutputStream fos = new FileOutputStream(logFile, true);

Review Comment:
   So `mvnd` uses the `Constants.MAVEN_LOGGER_LOG_FILE` constant to make sure 
the daemon log is redirected to disk, see 
https://github.com/apache/maven-mvnd/blob/db22a0a31bdcb000542a80c7d0ec491eab77f0bf/client/src/main/java/org/mvndaemon/mvnd/client/DaemonConnector.java#L437-L438
   
   This means that only the last execution for a given daemon will be logged. I 
don't really see that as an intuitive behavior, as the daemon aims at being 
reused, so the log should not be erased imho.  If you're not happy with 
changing the default, I'm fine with adding another property if you prefer.  
Note that in stock maven, this property is actually mostly useless, as it's 
being circumvented by another mechanism (you need a custom 
`ProjectBuildLogAppender` to get around that, such as in `mvnd`).  



-- 
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: issues-unsubscr...@maven.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to