lib/elasticsearch/extensions/test/cluster.rb in elasticsearch-extensions-0.0.12 vs lib/elasticsearch/extensions/test/cluster.rb in elasticsearch-extensions-0.0.13
- old
+ new
@@ -235,11 +235,11 @@
#
# @api private
#
def __print_cluster_info(port)
health = JSON.parse(Net::HTTP.get(URI("http://localhost:#{port}/_cluster/health")))
- nodes = JSON.parse(Net::HTTP.get(URI("http://localhost:#{port}/_nodes/?process")))
+ nodes = JSON.parse(Net::HTTP.get(URI("http://localhost:#{port}/_nodes/?process&http")))
master = JSON.parse(Net::HTTP.get(URI("http://localhost:#{port}/_cluster/state")))['master_node']
puts "\n",
('-'*80).ansi(:faint),
'Cluster: '.ljust(20).ansi(:faint) + health['cluster_name'].to_s.ansi(:faint),
@@ -247,10 +247,10 @@
'Nodes: '.ljust(20).ansi(:faint) + health['number_of_nodes'].to_s.ansi(:faint)
nodes['nodes'].each do |id, info|
m = id == master ? '+' : '-'
puts ''.ljust(20) +
- "#{m} #{info['name'].ansi(:bold)} | version: #{info['version']}, pid: #{info['process']['id']}".ansi(:faint)
+ "#{m} #{info['name'].ansi(:bold)} | version: #{info['version']}, pid: #{info['process']['id']}, address: #{info['http']['bound_address']}".ansi(:faint)
end
end
# Tries to load cluster health information
#