Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type LogEntryVars ¶
type LogEntryVars struct { Timestamp time.Time Query string Operation string Duration time.Duration Error error }
LogEntryVars variables made available t otemplate
type QueryHook ¶
type QueryHook struct {
// contains filtered or unexported fields
}
QueryHook wraps query hook
func NewQueryHook ¶
func NewQueryHook(opts QueryHookOptions) *QueryHook
NewQueryHook returns new instance
func (*QueryHook) AfterQuery ¶
func (h *QueryHook) AfterQuery(ctx context.Context, event *bun.QueryEvent)
AfterQuery convert a bun QueryEvent into a logrus message
func (*QueryHook) BeforeQuery ¶
BeforeQuery does nothing tbh
Click to show internal directories.
Click to hide internal directories.