elasticsearch

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Jul 3, 2019 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Codec added in v0.5.1

type Codec interface {
	EncodeElasticRecords(records []*models.Record) ([]*models.ElasticRecord, error)
}

func NewCodec added in v0.5.1

func NewCodec(logger log.Logger, config Config) Codec

type Config

type Config struct {
	Host               string
	User               string
	Pwd                string
	Index              string
	IndexColumn        string
	DocIDColumn        string
	BlacklistedColumns []string
	BulkTimeout        time.Duration
	Backoff            time.Duration
	TimeSuffix         TimeIndexSuffix
}

func NewConfig

func NewConfig() Config

type InsertResponse added in v0.5.3

type InsertResponse struct {
	AlreadyExists []string
	Retry         []*models.ElasticRecord
	Backoff       bool
}

type RecordDatabase

type RecordDatabase interface {
	Insert(records []*models.ElasticRecord) (*InsertResponse, error)
	ReadinessCheck() bool
	// contains filtered or unexported methods
}

func NewDatabase

func NewDatabase(logger log.Logger, config Config) RecordDatabase

type TimeIndexSuffix added in v0.6.0

type TimeIndexSuffix int
const (
	TimeSuffixDay  TimeIndexSuffix = 0
	TimeSuffixHour TimeIndexSuffix = 1
)

Jump to

Keyboard shortcuts

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