Method: Elasticsearch::API::Shutdown::Actions#get_node

Defined in:
lib/elasticsearch/api/actions/shutdown/get_node.rb

#get_node(arguments = {}) ⇒ Object

Retrieve status of a node or nodes that are currently marked as shutting down. Designed for indirect use by ECE/ESS and ECK. Direct use is not supported.

Parameters:

  • arguments (Hash) (defaults to: {})

    a customizable set of options

Options Hash (arguments):

  • :node_id (String)

    Which node for which to retrieve the shutdown status

  • :headers (Hash)

    Custom HTTP headers

See Also:



29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
# File 'lib/elasticsearch/api/actions/shutdown/get_node.rb', line 29

def get_node(arguments = {})
  arguments = arguments.clone
  headers = arguments.delete(:headers) || {}

  body = nil

  _node_id = arguments.delete(:node_id)

  method = Elasticsearch::API::HTTP_GET
  path   = if _node_id
             "_nodes/#{Utils.__listify(_node_id)}/shutdown"
           else
             "_nodes/shutdown"
           end
  params = {}

  Elasticsearch::API::Response.new(
    perform_request(method, path, params, body, headers)
  )
end