Documentation ¶
Overview ¶
Package monitor/db decorates database/sql drivers with query logging and timings
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterNewDriver ¶
func RegisterNewDriver(newname string, driver driver.Driver, mf DatabaseMonitor)
Types ¶
type DatabaseMonitor ¶
type DatabaseMonitor interface {
OnEvent(MonitorResult)
}
type MonitorResult ¶
type MonitoredConn ¶
type MonitoredConn struct {
// contains filtered or unexported fields
}
func (MonitoredConn) Close ¶
func (c MonitoredConn) Close() error
type MonitoredDriver ¶
type MonitoredDriver struct {
// contains filtered or unexported fields
}
type MonitoredStmt ¶
type MonitoredStmt struct {
// contains filtered or unexported fields
}
func (MonitoredStmt) Close ¶
func (c MonitoredStmt) Close() error
func (MonitoredStmt) NumInput ¶
func (c MonitoredStmt) NumInput() int
type MonitoredTx ¶
type MonitoredTx struct {
// contains filtered or unexported fields
}
func (MonitoredTx) Commit ¶
func (c MonitoredTx) Commit() error
func (MonitoredTx) Rollback ¶
func (c MonitoredTx) Rollback() error
Click to show internal directories.
Click to hide internal directories.