Hi,
 
I want to include the JDBCAppender as one of our appenders so that all error 
level messages will be written to a common database.  The problem is that the 
message content frequently contains a stack trace which is too large for the 
database column.  What I get right now is a row with the 'message' column 
empty/null.
 
I looked at extending JDBCAppender doAppend method, which would check the 
length of the message and truncate it after the first X bytes but the LogEvent 
doesn't provide getters so that I could create a different LogEvent with the 
truncated message.
 
What I really want to be able to do is use a format modifier on the message 
column, something like %2048m
to get the first 2k bytes for the column.
 
Any suggestions on other ways to get this implemented?
 

Reply via email to