Hi Jerome, We've added a number of enhancements to the version of log4j (only available via CVS) to address this specific issue (not yet released but available for use if you want to retrieve and build it), including:
* A number of appenders now add a configurable 'application' property to each event, as well as a 'hostname' property of the machine generating the events. * The new version of Chainsaw will route events with unique application-hostname pairs to a tab in the UI. See information on Chainsaw v2 here: http://logging.apache.org/log4j/docs/chainsaw.html - notice the tabs at the bottom of the screenshot (you may need to right-click on the image and view it to see it clearly) map to unique host machine/application pairs. See the latest version of socketappender here: http://cvs.apache.org/viewcvs.cgi/logging-log4j/src/java/org/apache/log4j/net/SocketAppender.java?rev=1.20&view=auto (added support for hostname and application properties) You can try the latest version of Chainsaw if you'd like just by running an ant script (Chainsaw v2 should work find with host machines using log4j1.2.8 and a socketappender), but of course the 1.2.8 version of socketappender doesn't append the application/hostname properties, but it should route to unique tabs based on the host machine. To try Chainsaw v2, download this ant script: http://logging.apache.org/log4j/docs/install-chainsaw.xml and run 'ant -f install-chainsaw.xml' If you have further questions, let us know. -----Original Message----- From: jerome moliere [mailto:[EMAIL PROTECTED] Sent: Wed 1/7/2004 9:31 AM To: [EMAIL PROTECTED] Cc: Subject: Log4j, IP or hostnames & cluster Hi all, I'm found of Log4J for a while, I'm using it anywhere but I'm facing a problem (not really) that I'm unable to resolve with current Log4J code. So this post claims to define a user need & a new feature or admitting that I don't know everything for this great tool. I'm working in a clustered environnement, with the same apps deployed on several machines..Using the same config file from my application server for log4J I can use a chainsaw console for viewing every trace from my application... But :( how could I distinct any error on the application server 1 with the same problem on the application server 2 ? My customers need really a way to administrate their application servers without using 1 chainsaw / server or without using one config file per server. I would add that the 2nd solution is used as a hack now but I would prefer a way to have the IP or hostname of the sender of the Logging Event. After an in depth look to the log4j architecture I think (may be wrong ?) that this latest class is the perfect way to add this data, eevry appender would be able to use it later... Adding a few lines of code for the PatternLayout & wee could use something like %i or %h for adding IP or hostnames in our traces.... If this architecture sounds good for you & that I don't miss some trivial way to achieve my goals I 'm ready to code this feature & to send you my patches (I can be paid to do this :) ). Your optinions would be greatly appreciated Sorry for my poor english written Cheers Jerome --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
