elastic

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Jan 20, 2020 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DeleteByDays

func DeleteByDays(parsedIndices []types.Index, days int, logtype string, loglevel string) int

DeleteByDays function is used to delete indexes by days. This function also provides a dry run option. It uses a list of indexes provided by the GetParsedIndices function. Set verbose true if you want more output details.

func DeleteIndex

func DeleteIndex(index string) bool

DeleteIndex function is used to delete indexes by providing the elastic endpoint and the index name. Set verbose true if you want more output details.

func GetClusterStatus

func GetClusterStatus(endpoint string, verbose bool) (types.Cluster, string)

GetClusterStatus function returns the cluster status details. Set verbose true if you want more output details.

func GetIndices

func GetIndices() ([]types.Index, string)

GetIndices function returns indices list from ElasticSearch. Set verbose true if you want more output details.

func GetIndicesWithoutIgnored

func GetIndicesWithoutIgnored() (parsedIndices []types.Index, err string)

GetIndicesWithoutIgnored function returns indices list with parsed fields filled removing the user ignored indexes set in the config file. Like the existence days of the index, loglevel, logtype and index date. Set verbose true if you want more output details.

func GetParsedIndices

func GetParsedIndices() (parsedIndices []types.Index, err string)

GetParsedIndices function returns indices list with parsed fields filled. Like the existence days of the index, loglevel, logtype and index date. Set verbose true if you want more output details.

func Reindex

func Reindex(originalIndexName string, newIndexName string) bool

Reindex function is used to rename an index by providing the elastic endpoint, the original index name and the new index name. Set verbose true if you want more output details.

Types

This section is empty.

Jump to

Keyboard shortcuts

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