Re: org.apache.logging.log4j.EventLogger

2015-10-15 Thread Ralph Goers
It takes a StructuredDataMessage because that is what I was using for Audit logging. To be honest, with the audit logging framework the user doesn’t even interact with the Message. The attributes of the Audit event are then placed into the StructuredDataMessage and then the RFC5424 formatted mes

Re: org.apache.logging.log4j.EventLogger

2015-10-15 Thread Mikael Ståldal
Is there a specific reason for EventLogger to take a StructuredDataMessage, or can we change it to take a Message to make it more generic? On Thu, Oct 15, 2015 at 2:13 PM, Mikael Ståldal wrote: > I think this code is quite ugly: > StructuredDataMessage msg = new StructuredDataMessage(confirm, nu

Re: org.apache.logging.log4j.EventLogger

2015-10-15 Thread Mikael Ståldal
I think this code is quite ugly: StructuredDataMessage msg = new StructuredDataMessage(confirm, null, "transfer"); msg.put("toAccount", toAccount); msg.put("fromAccount", fromAccount); msg.put("amount", amount); EventLogger.logEvent(msg); I would like to be able to do this in one statement. Perha

Re: org.apache.logging.log4j.EventLogger

2015-10-14 Thread Ralph Goers
See http://logging.apache.org/log4j/2.x/manual/eventlogging.html . I used this as the basis for an audit logging system at my former employer. I have every intention of creating a log4j-audit subproject that mimics what was done there

Re: org.apache.logging.log4j.EventLogger

2015-10-14 Thread Matt Sicker
Wait, wait, I was missing an important aspect here. Event logging is a different concept than location-based logging. Think of it as decentralized log messages (somewhat like StatusLogger in that regard). On 14 October 2015 at 21:51, Matt Sicker wrote: > From what I can grok, it looks like a way

Re: org.apache.logging.log4j.EventLogger

2015-10-14 Thread Matt Sicker
>From what I can grok, it looks like a way to log map-like messages in a way that's specified by the new syslog standard. Basically, if you're not using RFC 5424, it does seem confusing. On 16 September 2015 at 10:45, Gary Gregory wrote: > What is the point of this class? It does so little... wh

org.apache.logging.log4j.EventLogger

2015-09-16 Thread Gary Gregory
What is the point of this class? It does so little... what am I missing? Some better Javadocs are required to justify its existence IMO. Gary -- E-Mail: [email protected] | [email protected] Java Persistence with Hibernate, Second Edition JUnit in Action,