database

package
v0.0.0-...-bd3dd7f Latest Latest
Warning

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

Go to latest
Published: Jan 18, 2024 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ConnectionConfig

type ConnectionConfig struct {
	DBType   DatabaseType
	Host     string
	Port     string
	Username string
	Password string
	Database string
}

func (ConnectionConfig) DSN

func (c ConnectionConfig) DSN() (string, error)

type Database

type Database interface {
	BatchWrite(ctx context.Context, tableName string, chunks []any) error
	Connection() any
}

type DatabaseType

type DatabaseType string
const (
	Postgres   DatabaseType = "POSTGRES"
	ClickHouse DatabaseType = "CLICKHOUSE"
	MySQL      DatabaseType = "MYSQL"
)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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