Package com.codahale.metrics.jdbi3
Class InstrumentedSqlLogger
java.lang.Object
com.codahale.metrics.jdbi3.InstrumentedSqlLogger
- All Implemented Interfaces:
org.jdbi.v3.core.statement.SqlLogger
A
SqlLogger implementation for JDBI which uses the SQL objects' class names and
method names for nanosecond-precision timers.-
Field Summary
Fields inherited from interface org.jdbi.v3.core.statement.SqlLogger
NOP_SQL_LOGGER -
Constructor Summary
ConstructorsConstructorDescriptionInstrumentedSqlLogger(com.codahale.metrics.MetricRegistry registry) InstrumentedSqlLogger(com.codahale.metrics.MetricRegistry registry, StatementNameStrategy statementNameStrategy) -
Method Summary
Modifier and TypeMethodDescriptionvoidlogAfterExecution(org.jdbi.v3.core.statement.StatementContext context) voidlogException(org.jdbi.v3.core.statement.StatementContext context, SQLException ex) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.jdbi.v3.core.statement.SqlLogger
logBeforeExecution
-
Constructor Details
-
InstrumentedSqlLogger
public InstrumentedSqlLogger(com.codahale.metrics.MetricRegistry registry) -
InstrumentedSqlLogger
public InstrumentedSqlLogger(com.codahale.metrics.MetricRegistry registry, StatementNameStrategy statementNameStrategy)
-
-
Method Details
-
logAfterExecution
public void logAfterExecution(org.jdbi.v3.core.statement.StatementContext context) - Specified by:
logAfterExecutionin interfaceorg.jdbi.v3.core.statement.SqlLogger
-
logException
- Specified by:
logExceptionin interfaceorg.jdbi.v3.core.statement.SqlLogger
-