ck

package
v0.0.0-...-271e206 Latest Latest
Warning

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

Go to latest
Published: Sep 25, 2025 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CompressionMethodLZ4     CompressionMethod = "lz4"
	CompressionMethodZSTD    CompressionMethod = "zstd"
	CompressionMethodGZIP    CompressionMethod = "gzip"
	CompressionMethodDeflate CompressionMethod = "deflate"
	CompressionMethodBrotli  CompressionMethod = "br"

	ProtocolHTTP   Protocol = "http"
	ProtocolNative Protocol = "native"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type CompressionMethod

type CompressionMethod string

type Config

type Config struct {
	Host              string            `yaml:"host"`
	Database          string            `yaml:"database"`
	Username          string            `yaml:"username"`
	Password          string            `yaml:"password"`
	CompressionMethod CompressionMethod `yaml:"compression_method"`
	CompressionLevel  int               `yaml:"compressionLevel"`
	Protocol          Protocol          `yaml:"protocol"`
	DialTimeout       time.Duration     `yaml:"dialTimeout"`
	ReadTimeout       time.Duration     `yaml:"readTimeout"`
	Debug             bool              `yaml:"debug"`
	HttpHeaders       map[string]string `yaml:"http_headers"`
	Settings          map[string]any    `yaml:"setting"`
}

type Protocol

type Protocol string

type Provider

type Provider interface {
	NewSession(ctx context.Context) *gorm.DB
}

func NewCKFromConfig

func NewCKFromConfig(cfg *Config) (Provider, error)

Jump to

Keyboard shortcuts

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