sqlitecomp

package
v0.0.5 Latest Latest
Warning

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

Go to latest
Published: Aug 31, 2025 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Component

type Component struct {
	DB *sql.DB
	// contains filtered or unexported fields
}

func New

func New(cfg *Config, log *slog.Logger) (*Component, error)

func (*Component) Run

func (c *Component) Run() error

func (*Component) Stop

func (c *Component) Stop() error

type Config

type Config struct {
	FilePath        string        `yaml:"file_path" env-required:"true"`
	MaxOpenConns    int           `yaml:"max_open_conns" env-default:"1"`
	MaxIdleConns    int           `yaml:"max_idle_conns" env-default:"1"`
	ConnMaxLifetime time.Duration `yaml:"conn_max_lifetime" env-default:"0"`
}

Jump to

Keyboard shortcuts

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