Module: ProxES::Services::ES
- Defined in:
- lib/proxes/services/es.rb
Instance Method Summary collapse
Instance Method Details
#client ⇒ Object
9 10 11 12 13 14 15 16 17 |
# File 'lib/proxes/services/es.rb', line 9 def client @client ||= Elasticsearch::Client.new( url: ENV['ELASTICSEARCH_URL'], transport_options: { ssl: { verify: ENV['SSL_VERIFY_NONE'].to_i != 1 } }, logger: Ditty::Services::Logger.instance ) end |
#cluster_health(level = 'cluster') ⇒ Object
19 20 21 |
# File 'lib/proxes/services/es.rb', line 19 def cluster_health(level = 'cluster') client.cluster.health level: level end |