elasticsearch

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: May 27, 2025 License: MIT Imports: 3 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Action

type Action struct {
	Routing   *string
	IndexName string
	Type      ActionType
	Source    []byte
	ID        []byte
}

func NewDeleteAction

func NewDeleteAction(key []byte, routing *string) Action

func NewIndexAction

func NewIndexAction(key []byte, source []byte, routing *string) Action

func NewScriptUpdateAction added in v1.0.1

func NewScriptUpdateAction(id []byte, script Script, routing *string) Action

type ActionType

type ActionType string
const (
	Index        ActionType = "Index"
	Delete       ActionType = "Delete"
	ScriptUpdate ActionType = "ScriptUpdate"
)

type ResponseHandler

type ResponseHandler interface {
	OnSuccess(ctx *ResponseHandlerContext)
	OnError(ctx *ResponseHandlerContext)
	OnInit(ctx *ResponseHandlerInitContext)
}

type ResponseHandlerContext

type ResponseHandlerContext struct {
	Action *Action
	Err    error
}

type ResponseHandlerInitContext

type ResponseHandlerInitContext struct {
	Config              *config.Config
	ElasticsearchClient *es.Client
}

type Script added in v1.0.1

type Script struct {
	Params map[string]interface{} `json:"params,omitempty"`
	Source string                 `json:"source"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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