Thanks for the heads up.

Here is a possible workaround:

 public StringBuffer convert(LoggingEvent event) {
    if(buf.capacity() > 64) {
      buf = new StringBuffer(5);
    } else {
      buf.setLength(0);
    }
    return buf.append(String.valueOf(++counter));
  }




At 04:05 PM 9/29/2003 -0400, Shapira, Yoav wrote:


Howdy,
One minor question: isn't the example CountingPatternConverter using StringBuffer in a way that causes the bad memory leak documented in Bug Parade 4724129? (http://developer.java.sun.com/developer/bugParade/bugs/4724129.html)


If so, we should add a little note in the code telling users to be careful in using JDK 1.4.0 with this example converter on production systems.

Other than that -- cool stuff! I like the conversion words rather than characters, I like the dynamic conversion rules setup. Is the FormattingInfo empty for now? I didn't see anything in it.

Yoav Shapira
Millennium ChemInformatics


>-----Original Message----- >From: Ceki Gülcü [mailto:[EMAIL PROTECTED] >Sent: Monday, September 29, 2003 3:57 PM >To: [EMAIL PROTECTED] >Subject: PatternLayout docs > > >Here are some preliminary docs on PatternLayout version 1.3. > > https://www.qos.ch/logging/PatternLayout.html > > >-- >Ceki Gülcü > > For log4j documentation consider "The complete log4j manual" > ISBN: 2970036908 http://www.qos.ch/shop/products/clm_t.jsp > > import org.apache.Facetime; > ApacheCon US 2003, 18-21 November http://apachecon.com/ > > > >--------------------------------------------------------------------- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED]




This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you.



--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

-- Ceki Gülcü

     For log4j documentation consider "The complete log4j manual"
     ISBN: 2970036908 http://www.qos.ch/shop/products/clm_t.jsp

     import org.apache.Facetime;
     ApacheCon US 2003, 18-21 November http://apachecon.com/



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to