Package org.apache.cayenne.log
Interface JdbcEventLogger
- All Known Implementing Classes:
- CompactSlf4jJdbcEventLogger,- FormattedSlf4jJdbcEventLogger,- NoopJdbcEventLogger,- Slf4jJdbcEventLogger
public interface JdbcEventLogger
A logging service used by Cayenne to output database interactions.
- Since:
- 3.1
- 
Method SummaryModifier and Type Method Description booleanisLoggable()Returns true if current thread default log level is high enough to generate output.voidlog(String message)Logs an arbitrary message.voidlogBeginTransaction(String transactionLabel)voidlogCommitTransaction(String transactionLabel)voidlogGeneratedKey(DbAttribute attribute, Object value)voidlogQuery(String sql, ParameterBinding[] bindings)voidlogQueryError(Throwable th)voidlogQueryParameters(String label, ParameterBinding[] bindings)voidlogRollbackTransaction(String transactionLabel)voidlogSelectCount(int count, long time)voidlogSelectCount(int count, long time, String sql)voidlogUpdateCount(int count)
- 
Method Details- 
logLogs an arbitrary message.
- 
logGeneratedKey
- 
logQuery- Since:
- 4.0
 
- 
logQueryParameters- Since:
- 4.0
 
- 
logSelectCountvoid logSelectCount(int count, long time)
- 
logSelectCount- Parameters:
- count- of selected rows
- time- (milliseconds) time query took to run
- sql- SQL that was executed, printed when time exceeds timeThreshold
- Since:
- 4.0
 
- 
logUpdateCountvoid logUpdateCount(int count)
- 
logBeginTransaction
- 
logCommitTransaction
- 
logRollbackTransaction
- 
logQueryError
- 
isLoggableboolean isLoggable()Returns true if current thread default log level is high enough to generate output.
 
-