util

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

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

Go to latest
Published: Jun 18, 2017 License: Apache-2.0 Imports: 3 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ElasticsearchClient

type ElasticsearchClient struct {
	Endpoint string
	Index    string
}

func (*ElasticsearchClient) IndexDoc

func (c *ElasticsearchClient) IndexDoc(typeName, id string, data map[string]interface{}) (*InsertResponse, error)

type ElasticsearchConfig

type ElasticsearchConfig struct {
	Endpoint string `config:"elasticsearch.endpoint"`
	Index    string `config:"elasticsearch.index"`
}

type InsertResponse

type InsertResponse struct {
	Created bool   `json:"created"`
	Index   string `json:"_index"`
	Type    string `json:"_type"`
	ID      string `json:"_id"`
	Version int    `json:"_version"`
}

Jump to

Keyboard shortcuts

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