ohmyzsh/plugins/elasticsearch
2016-03-30 01:58:26 +02:00
..
_GET Added environment variable to change client node to query 2016-03-30 01:58:26 +02:00
elasticsearch.plugin.zsh Added environment variable to change client node to query 2016-03-30 01:58:26 +02:00
README.md Added environment variable to change client node to query 2016-03-30 01:58:26 +02:00

Elasticsearch

This plugin makes easy to use Elasticsearch API and it also offering autocomplete for common APIs. There are GET, HEAD, DELETE, PUT and POST commands.

Examples usage:

  • GET _cluster/health
  • GET _nodes/stats
  • GET _stats/fielddata?fields=*
  • GET _nodes/stats/indices/fielddata?fields=*
  • GET _cat
  • DELETE twitter

You should install json_reformat to format json output.

Instructions

If you'd prefer to specify an explicit Elasticsearch node client to query, you can set variable like so in .zshrc:

export CLIENT_ELK_NODE=client_node

Default is localhost.

Aliases

  • alias ech='GET _cluster/health': Cluster status health
  • alias ecs='GET _cluster/state': Allows to get a comprehensive state information of the whole cluster
  • alias ens='GET _nodes/stats': Allows to retrieve all of the cluster nodes statistics
  • alias esf='GET _stats/fielddata': Field data memory usage on index level

Author

Fedele Mantuano (Twitter: @fedelemantuano)