In your app code call the logger like this:

log.info("Employee: {}", myEmployee);

Then in the formatter, call event.getArgumentArray() - 
http://logback.qos.ch/xref/ch/qos/logback/classic/spi/LoggingEvent.html#143

Then look at each arg and check if it is an Employee. 

David

_______________________________________________
Logback-user mailing list
[email protected]
http://mailman.qos.ch/mailman/listinfo/logback-user

Reply via email to