dbfactory

package
v0.11.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 17, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Configs = configset.Set[Config]{
	Default: &Config{
		SlowQueryThreshold: 300 * time.Millisecond,
		Type:               gormkitteh.RequireExplicitDSNType,
	},
	Dev: &Config{
		SlowQueryThreshold: 200 * time.Millisecond,
		DSN:                "sqlite:file:" + filepath.Join(xdg.DataHomeDir(), "autokitteh.sqlite"),
		AutoMigrate:        true,
	},
	Test: &Config{},
}

Functions

func New

func New(z *zap.Logger, cfg *Config) (db.DB, error)

Types

type Config

type Config = gormkitteh.Config

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL