ch.qos.logback.classic.db
Class DBAppender
java.lang.Object
ch.qos.logback.core.spi.ContextAwareBase
ch.qos.logback.core.UnsynchronizedAppenderBase<E>
ch.qos.logback.core.db.DBAppenderBase<ILoggingEvent>
ch.qos.logback.classic.db.DBAppender
- All Implemented Interfaces:
- Appender<ILoggingEvent>, ContextAware, FilterAttachable<ILoggingEvent>, LifeCycle
public class DBAppender
- extends DBAppenderBase<ILoggingEvent>
The DBAppender inserts logging events into three database tables in a format
independent of the Java programming language.
For more information about this appender, please refer to the online manual
at http://logback.qos.ch/manual/appenders.html#DBAppender
- Author:
- Ceki Gülcü, Ray DeCampo, Sébastien Pennec
Methods inherited from class ch.qos.logback.core.spi.ContextAwareBase |
addError, addError, addInfo, addInfo, addStatus, addWarn, addWarn, getContext, getDeclaredOrigin, getStatusManager, setContext |
insertPropertiesSQL
protected String insertPropertiesSQL
insertExceptionSQL
protected String insertExceptionSQL
insertSQL
protected String insertSQL
GET_GENERATED_KEYS_METHOD
protected static final Method GET_GENERATED_KEYS_METHOD
DBAppender
public DBAppender()
setDbNameResolver
public void setDbNameResolver(DBNameResolver dbNameResolver)
start
public void start()
- Specified by:
start
in interface LifeCycle
- Overrides:
start
in class DBAppenderBase<ILoggingEvent>
subAppend
protected void subAppend(ILoggingEvent event,
Connection connection,
PreparedStatement insertStatement)
throws Throwable
- Specified by:
subAppend
in class DBAppenderBase<ILoggingEvent>
- Throws:
Throwable
secondarySubAppend
protected void secondarySubAppend(ILoggingEvent event,
Connection connection,
long eventId)
throws Throwable
- Specified by:
secondarySubAppend
in class DBAppenderBase<ILoggingEvent>
- Throws:
Throwable
getGeneratedKeysMethod
protected Method getGeneratedKeysMethod()
- Specified by:
getGeneratedKeysMethod
in class DBAppenderBase<ILoggingEvent>
getInsertSQL
protected String getInsertSQL()
- Specified by:
getInsertSQL
in class DBAppenderBase<ILoggingEvent>
insertProperties
protected void insertProperties(Map<String,String> mergedMap,
Connection connection,
long eventId)
throws SQLException
- Throws:
SQLException
insertThrowable
protected void insertThrowable(IThrowableProxy tp,
Connection connection,
long eventId)
throws SQLException
- Throws:
SQLException
Copyright © 2005-2013 QOS.ch. All Rights Reserved.