goquestorage

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Dec 12, 2025 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package goquestorage provides task storage implementations for different database backends.

Index

Constants

View Source
const (
	// PgDriver represents the PostgreSQL database driver.
	PgDriver = "postgres"
	// MysqlDriver represents the MySQL database driver.
	MysqlDriver  = "mysql"
	SqliteDriver = "sqlite3"
)

Database driver constants.

Variables

This section is empty.

Functions

func NewDBConn

func NewDBConn(ctx context.Context, cfg *Config) (*sqlx.DB, error)

NewDBConn creates a new database connection with configured settings.

Types

type Config

type Config struct {
	DSN             string
	Driver          string
	MaxOpenConn     int
	MaxIdleConn     int
	ConnMaxLifetime time.Duration
	ConnMaxIdleTime time.Duration
}

Config holds the configuration parameters for database connection settings.

Jump to

Keyboard shortcuts

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