writer

package
v0.0.0-...-6ee8545 Latest Latest
Warning

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

Go to latest
Published: Feb 7, 2023 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Context          context.Context
	MigrationJobName string // Label value to the progress metric.
	ConcurrentPush   int
	ClientConfig     utils.ClientConfig
	HTTPConfig       config.HTTPClientConfig

	ProgressEnabled    bool
	ProgressMetricName string // Metric name to main the last pushed maxt to remote write storage.

	GarbageCollectOnPush bool

	SigSlabRead chan *planner.Slab
	SigSlabStop chan struct{}
	// contains filtered or unexported fields
}

Config is config for writer.

type Write

type Write struct {
	Config
	// contains filtered or unexported fields
}

func New

func New(config Config) (*Write, error)

New returns a new remote write. It is responsible for writing to the remote write storage.

func (*Write) Run

func (w *Write) Run(errChan chan<- error)

Run runs the remote-writer. It waits for the remote-reader to give access to the in-memory data-block that is written after the most recent fetch. After reading the block and storing the data locally, it gives back the writing access to the remote-reader for further fetches.

func (*Write) Slabs

func (w *Write) Slabs() int64

Slabs returns the total number of slabs pushed to the remote-write storage.

Jump to

Keyboard shortcuts

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