blobstorconfig

package
v0.48.3 Latest Latest
Warning

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

Go to latest
Published: Aug 14, 2025 License: GPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// DepthDefault is the default shallow dir depth.
	DepthDefault = 4
	// CombinedCountLimitDefault is the default for the maximum number of objects to write into a single file.
	CombinedCountLimitDefault = 128
	// CombinedSizeLimitDefault is the default for the maximum size of the combined object file.
	CombinedSizeLimitDefault = 8 * 1024 * 1024
	// CombinedSizeThresholdDefault is the default for the minimal size of the object that won't be combined with others for writes.
	CombinedSizeThresholdDefault = 128 * 1024
	// PermDefault are default permission bits for BlobStor data.
	PermDefault = 0o640
	// DefaultFlushInterval is the default time interval between batch writes to disk.
	DefaultFlushInterval = 10 * time.Millisecond
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Blobstor added in v0.46.0

type Blobstor struct {
	Type                  string        `mapstructure:"type"`
	Path                  string        `mapstructure:"path"`
	Perm                  fs.FileMode   `mapstructure:"perm"`
	FlushInterval         time.Duration `mapstructure:"flush_interval"`
	Depth                 uint64        `mapstructure:"depth"`
	NoSync                *bool         `mapstructure:"no_sync"`
	CombinedCountLimit    int           `mapstructure:"combined_count_limit"`
	CombinedSizeLimit     internal.Size `mapstructure:"combined_size_limit"`
	CombinedSizeThreshold internal.Size `mapstructure:"combined_size_threshold"`
}

Blobstor contains configuration for a single BlobStor instance.

func (*Blobstor) Normalize added in v0.46.0

func (b *Blobstor) Normalize(def Blobstor)

Normalize fills in default values in Blobstor configuration if they are not set.

It uses the default values from Blobstor itself, and if they are not set too, it uses the default values from the package.

Jump to

Keyboard shortcuts

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