bulk

package
v0.0.0-...-d841f61 Latest Latest
Warning

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

Go to latest
Published: Jun 11, 2021 License: AGPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Bulk

type Bulk interface {
	AddPoints(po ...PointOp) error
	Perform() error
}

Bulk interface for InfluxDB

func New

func New(batchSize int, client influxmod.Client, config influxmod.BatchPointsConfig) (Bulk, error)

New creates a Bulk instance which is not thread safe.

func NewSafe

func NewSafe(unsafe Bulk) Bulk

NewSafe wraps un unsafe Bulk with a sync.RWMutex

type PointOp

type PointOp struct {
	Name   string
	Tags   map[string]string
	Fields map[string]interface{}
	Time   time.Time
}

PointOp regroups all parameters for influx.NewPoint. All members are mendatory.

Jump to

Keyboard shortcuts

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