Return-Path: Delivered-To: apmail-logging-log4net-user-archive@www.apache.org Received: (qmail 61566 invoked from network); 22 Nov 2005 09:25:02 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 22 Nov 2005 09:25:02 -0000 Received: (qmail 4882 invoked by uid 500); 22 Nov 2005 09:25:01 -0000 Delivered-To: apmail-logging-log4net-user-archive@logging.apache.org Received: (qmail 4589 invoked by uid 500); 22 Nov 2005 09:24:59 -0000 Mailing-List: contact log4net-user-help@logging.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: "Log4NET User" List-Id: Delivered-To: mailing list log4net-user@logging.apache.org Received: (qmail 4578 invoked by uid 99); 22 Nov 2005 09:24:59 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 22 Nov 2005 01:24:59 -0800 Received-SPF: pass (asf.osuosl.org: local policy) Received: from [212.247.164.74] (HELO POTTHOLMEN.softnetwork.se) (212.247.164.74) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 22 Nov 2005 01:26:32 -0800 Received: from seroseen ([131.115.75.49]) by softnetwork.se with MailEnable ESMTP; Tue, 22 Nov 2005 10:28:28 +0100 From: =?iso-8859-1?Q?G=F6ran_Roseen?= To: "'Log4NET User'" Subject: RE: PatternLayout - add time increment Date: Tue, 22 Nov 2005 10:24:32 +0100 Message-ID: <000f01c5ef46$8c337960$314b7383@se.org.softwareinnovation.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable X-Mailer: Microsoft Office Outlook 11 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180 Thread-Index: AcXvQ4bYbIsglcxpS4uqg9d6kphIWwAAMQ0w In-Reply-To: <41878339BD02A04899EA32098EE5868C3B9261@exchange.asd-software.cz> X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N OK, Urban, I understand. I don't think you will find what you are = looking for inside the framework though. Just a question; since you use the short form format specifier "%r", = does this mean that you use the old version 1.2.8? Or are you using 1.2.9? (It took me a while to find the list of format specifiers but they are = here: http://logging.apache.org/log4net/release/sdk/log4net.Layout.PatternLayou= t.h tml) My way to solve your problem would be to use %timestamp (or %r if you = want), and then process the log file separately. It would be quite easy to calculate the differences, using Excel for example. A (really small) note to our maintainers (Nicko et al.): The text on the manual page mentioned above says: "Each conversion specifier starts with a percent sign (%) and is = followed by optional format modifiers and a conversion character. The conversion character specifies the type of data, e.g. logger, level, date, thread name." "A conversion character" is not correct any more is it? Sincerely, G=F6ran Roseen -----Original Message----- From: Urban Jaroslav, Ing. [mailto:urban@asd-software.cz]=20 Sent: den 22 november 2005 10:03 To: log4net-user@logging.apache.org Subject: RE: PatternLayout - add time increment 2 G=F6ran Roseen ------------------------------------ Thanx for tip, but it is not exactly what I am looking for. This = timestamp just shows the time increment since logging is started. I am looking = rather for time difference between logged events. I found that for timestamp can be used char r, which is inserted in PatternLayout. Did you mean this? r - Used to output the number of milliseconds elapsed since the start of = the application until the creation of the logging event.=20 2 Nicko Cadell ----------------------------------- Just difference between actual event and event called before. See better example (see values in first bracket column): 2005-11-08 11:15:42,106 [0,012] [3444] INFO XmlService --->GetSoapBody 2005-11-08 11:15:42,341 [0,235] [3444] INFO XmlService = --->XSDValidation 2005-11-08 11:15:45,652 [3,311] [3444] INFO XmlService = --->XSLTValidation Then I can see the highest values of time increment, which I am = interested in. JU -----Original Message----- From: Urban Jaroslav, Ing.=20 Sent: Tuesday, November 08, 2005 12:24 PM To: log4net-user@logging.apache.org Subject: PatternLayout - add time increment Hi all, I looked for solution how I could insert to log file an time increment consecutive records. As I studied the PatternLayout for log4net, found no possibility to achieve it. Is there anyone who solved it or it is not possible? Thanks for any response, bye Jaroslav Urban An example: 2005-11-08 11:15:42,106 [0,000] [3444] INFO XmlService [] - -->GetSoapBody 2005-11-08 11:15:42,106 [0,000] [3444] INFO XmlService [] - -->Validation 2005-11-08 11:15:43,106 [1,000] [3444] INFO XmlService [] - -->XSLTValidation Specification: - log4net v1.1.1.33753 - IIS project - using Dot.Net Fr1.1