rgoers edited a comment on issue #284: LOG4J2-2639 - Allow logging calls to be 
constructed using a builder pattern
URL: https://github.com/apache/logging-log4j2/pull/284#issuecomment-505577467
 
 
   There should be no risk of a memory leak if log() is not called. The 
LogBuilders are owned by a thread local. If log() is not called then the next 
call to an "at" method would clear them for re-use. Even if one was dynamically 
created it would be garbage collected as soon as the it went out of scope.
   
   We could easily filter for markers in the withMarker method, but that would 
still wouldn't be able to use the Noop log builder. Even so, the overhead 
shouldn't be that high.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to