LogFilePatternReceiver will do this...you'd have to write a simple appender that processes the events the are generated by the receiver. Both your appender and the receiver need to be added to the log4j configuration file.
Scott On Wed, Mar 25, 2009 at 7:38 AM, Christophe Elek <[email protected]> wrote: > Hey Doug, > Yes I agree > > I was thinking I could use the same ConversionPattern > > So if my log4j properties lists > > log4j.appender.stdout.layout.ConversionPattern=%d{ABSOLUTE} [%t] %5p > %-50.50c - %m%n > > it would use the ConversionPatten as a regex and read each line ?? > > am I dreaming ? :) > > > Christophe Elek - Senior Software Analyst > IBM Rational Serviceability Architect > IBM Toronto Lab 8200 Warden Avenue, Markham, Ontario, L6G 1C7 > Phone Number: (905) 413-3467 > Email: [email protected] > * > **Rational Internal Serviceability > Portal*<http://w3.rchland.ibm.com/projects/process/swg/rational/serviceability/serviceability.shtml> > "Don't just fix the mistakes - fix whatever permitted the mistake in the > first place." Charles Fishman > ------------------------------ > > Web:http://www.ibm.com/software/rational/ > ------------------------------ > > > [image: Inactive hide details for Douglas E Wegscheid ---03/25/2009 > 10:14:11 AM---doing this with an arbitrary layout would be quite da]Douglas > E Wegscheid ---03/25/2009 10:14:11 AM---doing this with an arbitrary layout > would be quite daunting. > > > From: > Douglas E Wegscheid <[email protected]> > To: > "Log4J Users List" <[email protected]> > Cc: > "Log4J Users List" <[email protected]> > Date: > 03/25/2009 10:14 AM > Subject: > Re: import log into java model using log4j.properties > ------------------------------ > > > > doing this with an arbitrary layout would be quite daunting. > > if you use XMLLayout, then reading the XML and doing what you want would > be quite simple. > > Douglas E Wegscheid > Lead Technical Analyst, Whirlpool Corporation > (269)-923-5278 > > "A wrong note played hesitatingly is a wrong note. A wrong note played > with conviction is interpretation." > > > > Christophe Elek <[email protected]> wrote on 03/25/2009 09:03:36 AM: > > > I am looking for a solution that would do the 'reverse' of logging > > into a log file: reading a log file into java obects. > > > > I want a tool that would take a log4j.properties, a log generated > > using this log4j.properties and would transform each event into an > object > > Then I can run an analyzer :) > > > > Does it make sense ? :) > > > > Christophe Elek - Senior Software Analyst > > IBM Rational Serviceability Architect > > IBM Toronto Lab 8200 Warden Avenue, Markham, Ontario, L6G 1C7 > > Phone Number: (905) 413-3467 > > Email: [email protected] > > > > Rational Internal Serviceability Portal > > "Don't just fix the mistakes - fix whatever permitted the mistake in > > the first place." Charles Fishman > > [image removed] > > Web:http://www.ibm.com/software/rational/ > >
