Sha256: 9d76f9d2170d0c50fa9003e046df7621dae523fa966af334f141bcd7fbc0219b

Contents?: true

Size: 453 Bytes

Versions: 3

Compression:

Stored size: 453 Bytes

Contents

module Ej
  class Values
    attr_reader :client
    attr_reader :index
    attr_reader :logger

    def initialize(global_options)
      @logger =  Logger.new($stderr)
      @logger.level = global_options[:debug] ? Logger::DEBUG : Logger::INFO
      @client = Elasticsearch::Client.new(
        hosts: global_options[:host],
        logger: @logger,
        index: global_options[:index]
      )
      @index = global_options[:index]
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
ej-0.1.8 lib/ej/values.rb
ej-0.1.6 lib/ej/values.rb
ej-0.1.5 lib/ej/values.rb