crdb

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Sep 23, 2021 License: Apache-2.0 Imports: 24 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewCRDBDatastore

func NewCRDBDatastore(url string, options ...CRDBOption) (datastore.Datastore, error)

Types

type CRDBOption

type CRDBOption func(*crdbOptions)

func ConnMaxIdleTime

func ConnMaxIdleTime(idle time.Duration) CRDBOption

ConnMaxIdleTime is the duration after which an idle connection will be automatically closed by the health check. Default: no maximum

func ConnMaxLifetime

func ConnMaxLifetime(lifetime time.Duration) CRDBOption

ConnMaxLifetime is the duration since creation after which a connection will be automatically closed. Default: no maximum

func GCWindow

func GCWindow(window time.Duration) CRDBOption

GCWindow is the maximum age of a passed revision that will be considered valid. Default: 24h

func MaxOpenConns

func MaxOpenConns(conns int) CRDBOption

MaxOpenConns is the maximum size of the connection pool. Default: no maximum

func MinOpenConns

func MinOpenConns(conns int) CRDBOption

MinOpenConns is the minimum size of the connection pool. The health check will increase the number of connections to this amount if it had dropped below. Default: 0

func RevisionQuantization

func RevisionQuantization(bucketSize time.Duration) CRDBOption

RevisionQuantization is the time bucket size to which advertised revisions will be rounded. Default: 5s

func SplitAtEstimatedQuerySize

func SplitAtEstimatedQuerySize(splitAtEstimatedQuerySize units.Base2Bytes) CRDBOption

SplitAtEstimatedQuerySize is the query size at which it is split into two (or more) queries. Default: common.DefaultSplitAtEstimatedQuerySize

func WatchBufferLength

func WatchBufferLength(watchBufferLength uint16) CRDBOption

WatchBufferLength is the number of entries that can be stored in the watch buffer while awaiting read by the client. Default: 128

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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