gnodet commented on code in PR #1270: URL: https://github.com/apache/maven/pull/1270#discussion_r1365012668
########## maven-slf4j-provider/src/main/java/org/slf4j/impl/MavenSimpleLogger.java: ########## @@ -71,8 +78,13 @@ private void printStackTrace(Throwable t, PrintStream stream, String prefix) { stream.print(prefix); stream.print(" "); stream.print(builder().strong("at")); - stream.print(" " + e.getClassName() + "." + e.getMethodName()); - stream.print(builder().a(" (").strong(getLocation(e)).a(")")); + stream.print(" "); + stream.print(e.getClassName()); + stream.print("."); + stream.print(e.getMethodName()); + stream.print(" ("); + stream.print(builder().strong(getLocation(e))); + stream.print(")"); Review Comment: Are you sure this is interesting in terms of performances ? The benefit to avoid multiple buffer allocations may be balanced by the synchronisation / flushes on the underlying character/byte streams... ########## maven-slf4j-provider/src/main/java/org/slf4j/impl/MavenSimpleLogger.java: ########## @@ -30,6 +29,14 @@ * @since 3.5.0 */ public class MavenSimpleLogger extends SimpleLogger { + + private static final String TRACE_RENDERED_LEVEL = builder().trace("TRACE").build(); + private static final String DEBUG_RENDERED_LEVEL = builder().debug("DEBUG").build(); + private static final String INFO_RENDERED_LEVEL = builder().info("INFO").build(); + private static final String WARN_RENDERED_LEVEL = + builder().warning("WARNING").build(); + private static final String ERROR_RENDERED_LEVEL = builder().error("ERROR").build(); Review Comment: I'd rather have those as fields rather than static. In environments such as `mvnd`, this would avoid leaking system properties between builds. -- 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