aspose file tools*
The moose likes Java in General and the fly likes Getting Error Code to print while using LogBack. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "Getting Error Code to print while using LogBack." Watch "Getting Error Code to print while using LogBack." New topic
Author

Getting Error Code to print while using LogBack.

Vic Hood
Ranch Hand

Joined: Jan 05, 2011
Posts: 477

Hi folks ,
I'm trying to implement the SLF4J +LogBack logging solution to implement logging in my application .
I've modified the Pattern Expression in the logback.xml as below.


And its working fine . However I'd like to print the 'error code ' as well in my log say 404 or 500 as well . Any ideas on how I should be modifying my pattern expression for this?
Thanks.


Learning and Learning!-- Java all the way!
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Getting Error Code to print while using LogBack.
 
Similar Threads
Logging errors from jsp
Issue on LOGGING_EVENT table in classic logback
Java cookies ?
Searching a large text file...
questions on SLF4J: Defaulting to no-operation (NOP) logger implementation