class Stretcher::Cluster
Represents a cluster of servers should be reached typically through Server#cluster
Public Class Methods
new(server, options = {})
click to toggle source
# File lib/stretcher/cluster.rb, line 7 def initialize(server, options = {}) @server = server @logger = options[:logger] || server.logger end
Public Instance Methods
health(options = {})
click to toggle source
Get the health of the cluster
# File lib/stretcher/cluster.rb, line 13 def health(options = {}) request(:get, 'health', options) end
Private Instance Methods
path_uri(path = nil)
click to toggle source
# File lib/stretcher/cluster.rb, line 19 def path_uri(path = nil) p = @server.path_uri('/_cluster') path ? "#{p}/#{path}" : p end