format

package
v1.7.8 Latest Latest
Warning

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

Go to latest
Published: Aug 20, 2019 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WriteBucket

func WriteBucket(w Writer, start, end int64, rs *storage.ResultSet) error

WriteBucket reads data from rs covering the time range [start, end) and streams to w. The ResultSet must guarantee series+field keys are produced in ascending lexicographical order and values in ascending time order.

Types

type BucketWriter

type BucketWriter interface {
	Err() error
	BeginSeries(name, field []byte, typ influxql.DataType, tags models.Tags)
	EndSeries()

	WriteIntegerCursor(cur tsdb.IntegerArrayCursor)
	WriteFloatCursor(cur tsdb.FloatArrayCursor)
	WriteUnsignedCursor(cur tsdb.UnsignedArrayCursor)
	WriteBooleanCursor(cur tsdb.BooleanArrayCursor)
	WriteStringCursor(cur tsdb.StringArrayCursor)
	Close() error
}

type ConflictWriter

type ConflictWriter struct {
	// contains filtered or unexported fields
}

ConflictWriter is a Writer that redirects conflicting data to an alternate output.

func NewConflictWriter

func NewConflictWriter(w, conflict Writer) *ConflictWriter

NewConflictWriter returns a Writer that redirects invalid point data to the conflict Writer.

func (*ConflictWriter) Close

func (cw *ConflictWriter) Close() error

func (*ConflictWriter) NewBucket

func (cw *ConflictWriter) NewBucket(start, end int64) (bw BucketWriter, err error)

type Writer

type Writer interface {
	NewBucket(start, end int64) (BucketWriter, error)
	Close() error
}
var (
	// Discard is a Writer where all write calls succeed. The source data is also read completely, which can be useful
	// for testing performance.
	Discard Writer = &devNull{true}

	// DevNull is a Writer where all write calls succeed, however, no source data is read.
	DevNull Writer = &devNull{}
)

Directories

Path Synopsis
Package binary is a generated protocol buffer package.
Package binary is a generated protocol buffer package.

Jump to

Keyboard shortcuts

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