| Modifier and Type | Field and Description |
|---|---|
| private final ColumnInfo[] | |
| private PreparedStatement | |
| private final String |
| Access | Constructor and Description |
|---|---|
| public | DefaultJDBCTarget(final DataSource
the JDBC datasource dataSource, final String the table table, final ColumnInfo[] a ColumnInfo array columns)Creation of a new JDBC logging target. |
| Modifier and Type | Method and Description |
|---|---|
| protected synchronized void | closeConnection()
Overrides org. |
| protected final ColumnInfo | Returns: the column infothe index index)Return the column info for an supplied index. |
| private String | |
| private String | |
| protected String | |
| protected final String | |
| protected boolean | Returns: TRUE if the target is stale else FALSEOverrides org. |
| protected synchronized void | openConnection()
Overrides org. |
| protected synchronized void | output(final LogEvent
the log event. event)Implements abstract org. |
| protected void | specifyColumn(final PreparedStatement
the prepard statement statement, final int the index index, final LogEvent the log event event)Adds a single object into statement. |
| m_columns | back to summary |
|---|---|
| private final ColumnInfo[] m_columns | |
| m_statement | back to summary |
|---|---|
| private PreparedStatement m_statement | |
| m_table | back to summary |
|---|---|
| private final String m_table | |
| DefaultJDBCTarget | back to summary |
|---|---|
| public DefaultJDBCTarget(final DataSource dataSource, final String table, final ColumnInfo[] columns) Creation of a new JDBC logging target.
| |
| closeConnection | back to summary |
|---|---|
| protected synchronized void closeConnection() Overrides org. Close connection to underlying database. | |
| getColumn | back to summary |
|---|---|
| protected final ColumnInfo getColumn(final int index) Return the column info for an supplied index.
| |
| getContextMap | back to summary |
|---|---|
| private String getContextMap(final ContextMap map, final String aux) | |
| getStackTrace | back to summary |
|---|---|
| private String getStackTrace(final Throwable throwable) | |
| getStatementSQL | back to summary |
|---|---|
| protected String getStatementSQL() Return the SQL insert statement.
| |
| getTable | back to summary |
|---|---|
| protected final String getTable() Return the underlying table
| |
| isStale | back to summary |
|---|---|
| protected boolean isStale() Overrides org. Test if the target is stale.
| |
| openConnection | back to summary |
|---|---|
| protected synchronized void openConnection() Overrides org. Open connection to underlying database. | |
| output | back to summary |
|---|---|
| protected synchronized void output(final LogEvent event) Implements abstract org. Output a log event to DB. This must be implemented by subclasses.
| |
| specifyColumn | back to summary |
|---|---|
| protected void specifyColumn(final PreparedStatement statement, final int index, final LogEvent event) throws SQLException, IllegalStateException Adds a single object into statement.
| |