Versions in this module Expand all Collapse all v0 v0.1.2 Oct 30, 2025 v0.1.1 Oct 28, 2025 Changes in this version + type Client struct + func New(dialector gorm.Dialector, opts ...Option) (*Client, error) + func (c *Client) Close() error + func (c *Client) WithContext(ctx context.Context) *Client + func (c *Client) WithIgnoreRecordNotFound() *Client + type MetricData struct + Duration time.Duration + Error error + Operation string + RowsAffected int64 + SQL string + Table string + type MetricRecorder interface + RecordQuery func(data MetricData) + type Option func(*options) + func WithConnMaxIdleTime(idleTime time.Duration) Option + func WithConnMaxLifetime(lifetime time.Duration) Option + func WithDisableLog() Option + func WithIgnoreRecordNotFoundError() Option + func WithLogger(l logger.Logger) Option + func WithMaxIdleConns(count int) Option + func WithMaxOpenConns(count int) Option + func WithMetric(recorder MetricRecorder) Option + func WithSlowThreshold(threshold time.Duration) Option + func WithTrace(serviceName string) Option