Return-Path: Delivered-To: apmail-directory-dev-archive@www.apache.org Received: (qmail 48805 invoked from network); 29 Jun 2007 07:21:10 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 29 Jun 2007 07:21:10 -0000 Received: (qmail 12005 invoked by uid 500); 29 Jun 2007 07:21:12 -0000 Delivered-To: apmail-directory-dev-archive@directory.apache.org Received: (qmail 11963 invoked by uid 500); 29 Jun 2007 07:21:12 -0000 Mailing-List: contact dev-help@directory.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Apache Directory Developers List" Delivered-To: mailing list dev@directory.apache.org Received: (qmail 11952 invoked by uid 99); 29 Jun 2007 07:21:12 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 29 Jun 2007 00:21:12 -0700 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (herse.apache.org: domain of elecharny@gmail.com designates 209.85.132.241 as permitted sender) Received: from [209.85.132.241] (HELO an-out-0708.google.com) (209.85.132.241) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 29 Jun 2007 00:21:08 -0700 Received: by an-out-0708.google.com with SMTP id c31so164235ana for ; Fri, 29 Jun 2007 00:20:48 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:reply-to:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=R8R/YKv0/J/Im9Rs5EnxZCiUObKzFpmMOS1ag3YDw9Dg1s/bKwcq+VL7aKZGU6f+hSMI1IvSznHEa6MjuyLJNtFEfEgo/3JX2p+OwjobmmT5DFTONGYFHxfm+TYv3V84wGqiFTkXuAb0yXIcCkgkvy2CjmPbZ1riGuBNgBn21ok= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:reply-to:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=lDqSzrtcP8YrmeyrxDEgrHd5vHEA/aAtLyG/pX80NX4huo6Jh6LGZ7HOvgS93ESyQPHNYeL3M5mGmOZWulv86H/XcYCxzgDqShuufBeuhdRxJr6YsfZ4eUpWXIZ0j7L9dCboePBJDAc9/Repg7Y8C+jrXIS9hSrbcYCo6faOaAw= Received: by 10.100.42.7 with SMTP id p7mr1937872anp.1183101648058; Fri, 29 Jun 2007 00:20:48 -0700 (PDT) Received: by 10.100.31.6 with HTTP; Fri, 29 Jun 2007 00:20:48 -0700 (PDT) Message-ID: Date: Fri, 29 Jun 2007 09:20:48 +0200 From: "Emmanuel Lecharny" Reply-To: elecharny@iktek.com To: "Apache Directory Developers List" Subject: Re: nlog4j problems under load Cc: user@slf4j.org, ceki@qos.ch In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: X-Virus-Checked: Checked by ClamAV on apache.org Hi Norval, good to see that you are back ! I hope Ceki can help you on this, because I'm afraid we are not exactly Log4j specialists on Directory project... What about Logback, does it behave the same ? Emmanuel On 6/29/07, Norval Hope wrote: > Hi, > > I am in the final stages of preparing a release that builds on top of > ApacheDS, and consequently must use an slf4j compliant logging library so= I > used nlog4j 1.2.25 (as AD does). > > I have a requirement to have separate appenders created dynamically at > runtime and adopted the approach shown in the small attached test/config > files, which was: > 1. to have a template appender copied every time a new appender is > required > 2. have a stub logger used only so that I can discover the template > appender when I need it (as the template appender is in this loggers > appender list in the .properties config file) > 3. to dynamically create a logger intended to send output to the > dynamically created appender only (additivity is false and no other logge= r > knows about each particular appender instance). > > This all works fine under normal load, but noted some problems under heav= y > logging load so I wrote the stand alone test to investigate. > > Running the test with 2 threads and no delay ("java nlog4jtest.NLog4jTest= 2 > 0") causing problems immediately on a dual core laptop running windows xp= : > 1. log messages from one logger appear against appenders to which they = are > not linked > 2. partial log messages are evident, where headers are missing etc. > Using a delay of 5 milliseconds improved the situation but still both > problems were evident. > > On a single cpu windows box running xp, "java nlog4jtest.NLog4jTest 10 0" > also evidenced both problems too. > > I know I'm making use of a bespoke approach here, so I'm hoping I'm doing > something wrong in my implementation or breaking some contract I'm not aw= are > of. I basically can't ship with logging in this state and can't migrate t= o > logback due to LGPL license, which is a problem for the ApacheDS project > too. > > Any expert advice about alternative implementation approaches or how to b= est > approach debugging would be greatly appreciated. > > Many Thanks, > Norval > --=20 Regards, Cordialement, Emmanuel L=E9charny www.iktek.com