Sha256: 4d840f3428d15200268281c90b970c66bf66c107e290ffbbc11da7fc8aae1801

Contents?: true

Size: 609 Bytes

Versions: 59

Compression:

Stored size: 609 Bytes

Contents

# encoding: utf-8
require_relative "elasticsearch_resource"

module LogStash module Modules class ElasticsearchConfig
  attr_reader :index_name

  # We name it `modul` here because `module` has meaning in Ruby.
  def initialize(modul, settings)
    @directory = ::File.join(modul.directory, "elasticsearch")
    @name = modul.module_name
    @settings = settings
    @full_path = ::File.join(@directory, "#{@name}.json")
    @index_name = @settings.fetch("elasticsearch.template_path", "_template")
  end

  def resources
    [ElasticsearchResource.new(@index_name, "not-used", @full_path)]
  end
end end end

Version data entries

59 entries across 59 versions & 1 rubygems

Version Path
logstash-core-6.8.23-java lib/logstash/modules/elasticsearch_config.rb
logstash-core-6.8.22-java lib/logstash/modules/elasticsearch_config.rb
logstash-core-6.8.21-java lib/logstash/modules/elasticsearch_config.rb
logstash-core-6.8.20-java lib/logstash/modules/elasticsearch_config.rb
logstash-core-6.8.19-java lib/logstash/modules/elasticsearch_config.rb
logstash-core-6.8.18-java lib/logstash/modules/elasticsearch_config.rb
logstash-core-6.8.17-java lib/logstash/modules/elasticsearch_config.rb
logstash-core-6.8.16-java lib/logstash/modules/elasticsearch_config.rb
logstash-core-6.8.15-java lib/logstash/modules/elasticsearch_config.rb
logstash-core-6.8.14-java lib/logstash/modules/elasticsearch_config.rb
logstash-core-6.8.13-java lib/logstash/modules/elasticsearch_config.rb
logstash-core-6.8.12-java lib/logstash/modules/elasticsearch_config.rb
logstash-core-6.8.11-java lib/logstash/modules/elasticsearch_config.rb
logstash-core-6.8.10-java lib/logstash/modules/elasticsearch_config.rb
logstash-core-6.8.9-java lib/logstash/modules/elasticsearch_config.rb
logstash-core-6.8.8-java lib/logstash/modules/elasticsearch_config.rb
logstash-core-6.8.7-java lib/logstash/modules/elasticsearch_config.rb
logstash-core-7.5.2-java lib/logstash/modules/elasticsearch_config.rb
logstash-core-7.5.1-java lib/logstash/modules/elasticsearch_config.rb
logstash-core-6.8.6-java lib/logstash/modules/elasticsearch_config.rb