lib/kishu/client.rb in kishu-0.0.1 vs lib/kishu/client.rb in kishu-1.0.0
- old
+ new
@@ -9,11 +9,11 @@
class Client
def initialize
if ES_HOST == "localhost:9200" || ES_HOST == "elasticsearch:9200"
- @client = Elasticsearch::Client.new(host: ES_HOST, user: "elastic", password: ELASTIC_PASSWORD, transport_options: { request: { timeout: 3600, open_timeout: 3600 }}) do |f|
+ @client = Elasticsearch::Client.new(host: ES_HOST, user: "elastic", password: ELASTIC_PASSWORD, transport_options: { request: { timeout: 3600}}) do |f|
f.adapter Faraday.default_adapter
end
else
@client = Elasticsearch::Client.new(host: ES_HOST, port: '80', scheme: 'http') do |f|
f.request :aws_sigv4,
@@ -60,11 +60,10 @@
size: 1,
query: {
query_string: {
query: "*"
}
- },
- aggregations: aggregations(options)
+ }
},
index: "resolutions"
).dig("hits","hits",0,"_source","logdate")
end