config

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Mar 30, 2021 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Overview

Package config defines a variety of injectable configuration types that may be shared across the store packages.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	// Used to limit concurrent DB operations at the chunk level.
	ChunkConcurrency int
	// The ideal size of a chunk.
	ChunkSize int
	// A database connection string.
	ConnectString string
	// The amount of time that a deleted file, dangling rope, or
	// dangling chunk should be retained.
	PurgeDuration time.Duration
	// The deletion batch size to use when purging old data.
	PurgeLimit int
	// If any of the nodes in the cluster report read amplification
	// above this threshold, we'll (effectively) lower ChunkConcurrency.
	ReadAmplificationBackoff int
	// Keys for validating HMAC-based JWT tokens. The zeroth entry will
	// be used to sign new tokens.
	SigningKeys [][]byte
	// The period of time for which an upload may be pending.
	UploadTimeout time.Duration
	// contains filtered or unexported fields
}

Config contains the various pieces of data used by the store code.

func (*Config) Bind

func (c *Config) Bind(flags *pflag.FlagSet)

Bind adds to the given flag set and

func (*Config) Configure

func (c *Config) Configure(_ context.Context) error

Configure is used to cooperate with the start CLI package.

Jump to

Keyboard shortcuts

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