Versions in this module Expand all Collapse all v1 v1.1.0 Nov 3, 2023 v1.0.4 Aug 19, 2022 Changes in this version + const MutexTableName + const RefreshInterval + const TTL + func ExtractCustomParams(conn string, params []string) (map[string]string, error) + func GenerateAdvisoryLockID(databaseName, schemaName string) (string, error) + func GetContext(timeoutInSeconds int) (context.Context, context.CancelFunc) + func IsLockable(x interface{}) bool + func MakeLockKey(key string) (string, error) + func NextWaitInterval(lastWaitInterval time.Duration, err error) time.Duration + func RemoveParamsFromURL(conn string, params []string) (string, error) + type AppError struct + Driver string + Message string + OrigErr error + func (ae *AppError) Error() string + type Config struct + MigrationMaxSize int + MigrationsTable string + StatementTimeoutInSecs int + type DatabaseError struct + Command string + Driver string + Message string + OrigErr error + Query []byte + func (de *DatabaseError) Error() string + type DefaultLogger struct + func (DefaultLogger) Printf(format string, v ...interface{}) + func (DefaultLogger) Println(v ...interface{}) + type Driver interface + AppliedMigrations func() ([]*models.Migration, error) + Apply func(migration *models.Migration, saveVersion bool) error + Close func() error + Ping func() error + SetConfig func(key string, value interface{}) error + type Lockable interface + DriverName func() string + type Locker interface + Lock func(ctx context.Context) error + Unlock func() error + type Logger interface + Printf func(format string, v ...interface{}) + Println func(v ...interface{})