v5

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Mar 16, 2017 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

Client represents Elasticsearch API client

func NewClient

func NewClient(clusterURL string, httpClient *http.Client) (*Client, error)

NewClient creates new Client object

func (*Client) DisableReallocation

func (c *Client) DisableReallocation() error

DisableReallocation enables shard reallocation Modifies cluster.routing.allocation.enable to "none" https://www.elastic.co/guide/en/elasticsearch/reference/1.5/cluster-update-settings.html

func (*Client) EnableReallocation

func (c *Client) EnableReallocation() error

EnableReallocation enables shard reallocation Modifies cluster.routing.allocation.enable to "all" https://www.elastic.co/guide/en/elasticsearch/reference/1.5/cluster-update-settings.html

func (*Client) ExcludeNodeFromAllocation

func (c *Client) ExcludeNodeFromAllocation(nodeName string) error

ExcludeNodeFromAllocation excludes the given node from shard allocation group https://www.elastic.co/guide/en/elasticsearch/reference/current/allocation-filtering.html

func (*Client) ListNodes

func (c *Client) ListNodes() ([]string, error)

ListNodes returns the list of node names

func (*Client) ListShardsOnNode

func (c *Client) ListShardsOnNode(nodeName string) ([]string, error)

ListShardsOnNode returns the list of shards on the given node

func (*Client) Shutdown

func (c *Client) Shutdown(nodeName string) error

Shutdown does nothing, because Elasticsearch 2.x does not have shutdown API

Jump to

Keyboard shortcuts

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