fluent-plugin-elasticsearch 3.5.1 → 3.5.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 157eb6e8f0c5412c1eec69c86be920e6737c2ed172cfd62618d284ae99bb68fc
4
- data.tar.gz: 30d6c01d4626bbc016fe97e95caf529e1be40afa48196e806aebbc02457b7119
3
+ metadata.gz: ef45e29f8c3a6ff15a0abd5cf6161bc17774c48c84a5d768b33b7b9d0482d9ea
4
+ data.tar.gz: 2a05a508cbf5763de05e58e1a3a8a3549a36e85610684fd7365825fbcec1b056
5
5
  SHA512:
6
- metadata.gz: 5b2830f040fda0e697a7b6e54eff371d78858637476eae95e8bbce7edc7334cb38b29977961b0ccf4f52aebb084638e4b4a8f3a8f5023766d28ec1781ab5b400
7
- data.tar.gz: 8518ef11cdeca51a115e0be1201df72df0639c33e00f2b200148ede002e32d2a734cbba4e7b3accc16d25eed91120615277ba1ac40e39a901198f0d60425443a
6
+ metadata.gz: 29565f1f6a3a11de6a96ee9961c3361b51cb688bf4dac65702a9977687402af454b55526df3532c628fdf2369e733a65c4dda4526c4f2b896a094d1885c854f2
7
+ data.tar.gz: 2970335562ad4bb92e8de45862999ff974b4c76dda3a8257c14d7559ed0a04e91bb37b2aa793d3cfee847637475a27fae59cb8b4d3c49a1962008ce626b0ad1a
data/History.md CHANGED
@@ -2,6 +2,9 @@
2
2
 
3
3
  ### [Unreleased]
4
4
 
5
+ ### 3.5.2
6
+ - Fix `@meta_config_map` creation timing (#592)
7
+
5
8
  ### 3.5.1
6
9
  - Configurable split request size threshold (#586)
7
10
 
@@ -3,7 +3,7 @@ $:.push File.expand_path('../lib', __FILE__)
3
3
 
4
4
  Gem::Specification.new do |s|
5
5
  s.name = 'fluent-plugin-elasticsearch'
6
- s.version = '3.5.1'
6
+ s.version = '3.5.2'
7
7
  s.authors = ['diogo', 'pitr']
8
8
  s.email = ['pitr.vern@gmail.com', 'me@diogoterror.com']
9
9
  s.description = %q{Elasticsearch output plugin for Fluent event collector}
@@ -205,13 +205,6 @@ EOC
205
205
  end
206
206
  end
207
207
 
208
- # Consider missing the prefix of "$." in nested key specifiers.
209
- @id_key = convert_compat_id_key(@id_key) if @id_key
210
- @parent_key = convert_compat_id_key(@parent_key) if @parent_key
211
- @routing_key = convert_compat_id_key(@routing_key) if @routing_key
212
-
213
- @meta_config_map = create_meta_config_map
214
-
215
208
  @serializer_class = nil
216
209
  begin
217
210
  require 'oj'
@@ -285,7 +278,13 @@ EOC
285
278
  log.warn "To prevent events traffic jam, you should specify 2 or more 'flush_thread_count'."
286
279
  end
287
280
 
281
+ # Consider missing the prefix of "$." in nested key specifiers.
282
+ @id_key = convert_compat_id_key(@id_key) if @id_key
283
+ @parent_key = convert_compat_id_key(@parent_key) if @parent_key
284
+ @routing_key = convert_compat_id_key(@routing_key) if @routing_key
285
+
288
286
  @routing_key_name = configure_routing_key_name
287
+ @meta_config_map = create_meta_config_map
289
288
  @current_config = nil
290
289
 
291
290
  @ignore_exception_classes = @ignore_exceptions.map do |exception|
@@ -475,7 +475,7 @@ class ElasticsearchOutput < Test::Unit::TestCase
475
475
  # creation
476
476
  stub_request(:put, "https://john:doe@logs.google.com:777/es//_template/myapp_alias_template").
477
477
  to_return(:status => 200, :body => "", :headers => {})
478
-
478
+
479
479
  driver(config)
480
480
 
481
481
  assert_requested(:put, "https://john:doe@logs.google.com:777/es//_template/myapp_alias_template", times: 1)
@@ -520,7 +520,7 @@ class ElasticsearchOutput < Test::Unit::TestCase
520
520
  # put the alias for the index
521
521
  stub_request(:put, "https://john:doe@logs.google.com:777/es//%3Cmylogs-myapp-%7Bnow%2Fw%7Bxxxx.ww%7D%7D-000001%3E/_alias/myapp_deflector").
522
522
  to_return(:status => 200, :body => "", :headers => {})
523
-
523
+
524
524
  driver(config)
525
525
 
526
526
  assert_requested(:put, "https://john:doe@logs.google.com:777/es//_template/myapp_alias_template", times: 1)
@@ -584,7 +584,7 @@ class ElasticsearchOutput < Test::Unit::TestCase
584
584
  # creation
585
585
  stub_request(:put, "https://john:doe@logs.google.com:777/es//_template/myapp_alias_template").
586
586
  to_return(:status => 200, :body => "", :headers => {})
587
-
587
+
588
588
  driver(config)
589
589
 
590
590
  assert_requested(:put, "https://john:doe@logs.google.com:777/es//_template/myapp_alias_template", times: 1)
@@ -629,7 +629,7 @@ class ElasticsearchOutput < Test::Unit::TestCase
629
629
  # put the alias for the index
630
630
  stub_request(:put, "https://john:doe@logs.google.com:777/es//%3Cmylogs-myapp-%7Bnow%2Fd%7D-000001%3E/_alias/myapp_deflector").
631
631
  to_return(:status => 200, :body => "", :headers => {})
632
-
632
+
633
633
  driver(config)
634
634
 
635
635
  assert_requested(:put, "https://john:doe@logs.google.com:777/es//_template/myapp_alias_template", times: 1)
@@ -2049,7 +2049,7 @@ class ElasticsearchOutput < Test::Unit::TestCase
2049
2049
 
2050
2050
  class AddsRoutingKeyWhenConfiguredTest < self
2051
2051
  def test_es6
2052
- driver('', 6).configure("routing_key routing_id\n")
2052
+ driver("routing_key routing_id\n", 6)
2053
2053
  stub_elastic
2054
2054
  driver.run(default_tag: 'test') do
2055
2055
  driver.feed(sample_record)
@@ -2058,7 +2058,7 @@ class ElasticsearchOutput < Test::Unit::TestCase
2058
2058
  end
2059
2059
 
2060
2060
  def test_es7
2061
- driver('', 7).configure("routing_key routing_id\n")
2061
+ driver("routing_key routing_id\n", 7)
2062
2062
  stub_elastic
2063
2063
  driver.run(default_tag: 'test') do
2064
2064
  driver.feed(sample_record)
@@ -737,7 +737,7 @@ class ElasticsearchOutputDynamic < Test::Unit::TestCase
737
737
 
738
738
  class AddsRoutingKeyWhenConfiguredTest < self
739
739
  def test_es6
740
- driver('', 6).configure("routing_key routing_id\n")
740
+ driver("routing_key routing_id\n", 6)
741
741
  stub_elastic
742
742
  driver.run(default_tag: 'test') do
743
743
  driver.feed(sample_record)
@@ -746,7 +746,7 @@ class ElasticsearchOutputDynamic < Test::Unit::TestCase
746
746
  end
747
747
 
748
748
  def test_es7
749
- driver('', 7).configure("routing_key routing_id\n")
749
+ driver("routing_key routing_id\n", 7)
750
750
  stub_elastic
751
751
  driver.run(default_tag: 'test') do
752
752
  driver.feed(sample_record)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fluent-plugin-elasticsearch
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.5.1
4
+ version: 3.5.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - diogo
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2019-05-13 00:00:00.000000000 Z
12
+ date: 2019-05-24 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: fluentd