logstash-core 5.6.3-java → 5.6.4-java

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
  SHA1:
3
- metadata.gz: fef2dc1c5cc3cbee836c5250ca4c9d125ac18302
4
- data.tar.gz: 710215041fb6cce31484f588d2d141de3d126caf
3
+ metadata.gz: df1559580d4898d9d5904c366fb99e6fdc01fe9a
4
+ data.tar.gz: 42b5968d158d63d05e85f1ffbf9f2e4dd20ad7c1
5
5
  SHA512:
6
- metadata.gz: 5a5a8302cdb3e5a947eaa0888bb284b3f05011ac0d928420ec32b0ea3bff90721580d81c2896556647c2c21b354c14a31e68d2926f1ee0d6c186d0adb4954198
7
- data.tar.gz: 36061c2b853e3a70b53a1bfb929597ab1d9f3f489596afe18972ea8d3f941446b5f92f63a92329a08fae2efb219fe9d53c6a49991040f7b25b7147851ba9ee76
6
+ metadata.gz: 4070075f61282df4c7114c52560848611838d5024e06360131cc77f40daa730ff6e91952b554749c347e9a05d46713fe04466171a750ff6700c2711f9ed5c075
7
+ data.tar.gz: cc68623a75280eebe05286a765b62ffc56afdc468f9d68d54443cdd8756c1ef73f777bf0415fd98d3fbf80e976dc710b693f85aeca0bba2067dbcea5e4c958c3
data/gemspec_jars.rb CHANGED
@@ -2,6 +2,7 @@
2
2
  # runtime dependencies to generate this gemspec dependencies file to be eval'ed by the gemspec
3
3
  # for the jar-dependencies requirements.
4
4
 
5
+ gem.requirements << "jar org.apache.logging.log4j:log4j-slf4j-impl, 2.6.2"
5
6
  gem.requirements << "jar org.apache.logging.log4j:log4j-api, 2.6.2"
6
7
  gem.requirements << "jar org.apache.logging.log4j:log4j-core, 2.6.2"
7
8
  gem.requirements << "jar com.fasterxml.jackson.core:jackson-core, 2.9.1"
Binary file
@@ -5,7 +5,9 @@ rescue LoadError
5
5
  require 'org/apache/logging/log4j/log4j-core/2.6.2/log4j-core-2.6.2.jar'
6
6
  require 'com/fasterxml/jackson/core/jackson-databind/2.9.1/jackson-databind-2.9.1.jar'
7
7
  require 'org/apache/logging/log4j/log4j-api/2.6.2/log4j-api-2.6.2.jar'
8
+ require 'org/slf4j/slf4j-api/1.7.21/slf4j-api-1.7.21.jar'
8
9
  require 'com/fasterxml/jackson/core/jackson-annotations/2.9.1/jackson-annotations-2.9.1.jar'
10
+ require 'org/apache/logging/log4j/log4j-slf4j-impl/2.6.2/log4j-slf4j-impl-2.6.2.jar'
9
11
  require 'com/fasterxml/jackson/module/jackson-module-afterburner/2.9.1/jackson-module-afterburner-2.9.1.jar'
10
12
  require 'com/fasterxml/jackson/dataformat/jackson-dataformat-cbor/2.9.1/jackson-dataformat-cbor-2.9.1.jar'
11
13
  require 'com/fasterxml/jackson/core/jackson-core/2.9.1/jackson-core-2.9.1.jar'
@@ -15,7 +17,9 @@ if defined? Jars
15
17
  require_jar( 'org.apache.logging.log4j', 'log4j-core', '2.6.2' )
16
18
  require_jar( 'com.fasterxml.jackson.core', 'jackson-databind', '2.9.1' )
17
19
  require_jar( 'org.apache.logging.log4j', 'log4j-api', '2.6.2' )
20
+ require_jar( 'org.slf4j', 'slf4j-api', '1.7.21' )
18
21
  require_jar( 'com.fasterxml.jackson.core', 'jackson-annotations', '2.9.1' )
22
+ require_jar( 'org.apache.logging.log4j', 'log4j-slf4j-impl', '2.6.2' )
19
23
  require_jar( 'com.fasterxml.jackson.module', 'jackson-module-afterburner', '2.9.1' )
20
24
  require_jar( 'com.fasterxml.jackson.dataformat', 'jackson-dataformat-cbor', '2.9.1' )
21
25
  require_jar( 'com.fasterxml.jackson.core', 'jackson-core', '2.9.1' )
@@ -198,6 +198,16 @@ class LogStash::Agent
198
198
  end
199
199
  end
200
200
 
201
+ def get_running_user_defined_pipelines
202
+ found = @upgrade_mutex.synchronize do
203
+ @pipelines.select do |pipeline_id, _|
204
+ pipeline = @pipelines[pipeline_id]
205
+ pipeline.running? && !pipeline.system?
206
+ end
207
+ end
208
+ found
209
+ end
210
+
201
211
  def close_pipeline(id)
202
212
  pipeline = @pipelines[id]
203
213
  if pipeline
@@ -142,7 +142,8 @@ module LogStash; module Config; module AST
142
142
  definitions << "define_singleton_method :#{type}_func do |event|"
143
143
  definitions << " targeted_outputs = []" if type == "output"
144
144
  definitions << " events = event" if type == "filter"
145
- definitions << " @logger.debug? && @logger.debug(\"#{type} received\", \"event\" => event.to_hash)"
145
+ definitions << " @logger.debug? && @logger.debug(\"#{type} received\", \"event\" => event.to_hash)" if type == "output"
146
+ definitions << " @logger.debug? && events.each { |e| @logger.debug(\"#{type} received\", \"event\" => e.to_hash)}" if type == "filter"
146
147
 
147
148
  sections.select { |s| s.plugin_type.text_value == type }.each do |s|
148
149
  definitions << s.compile.split("\n", -1).map { |e| " #{e}" }
@@ -10,10 +10,15 @@ module LogStash module Instrument module PeriodicPoller
10
10
  end
11
11
 
12
12
  def collect
13
- _, pipeline = @agent.running_pipelines.first
14
- unless pipeline.nil?
15
- pipeline.collect_dlq_stats
13
+ pipelines = @agent.get_running_user_defined_pipelines
14
+ unless pipelines.nil?
15
+ pipelines.each {|_, pipeline|
16
+ unless pipeline.nil?
17
+ pipeline.collect_dlq_stats
18
+ end
19
+ }
16
20
  end
17
21
  end
18
22
  end
19
23
  end end end
24
+
@@ -11,9 +11,13 @@ module LogStash module Instrument module PeriodicPoller
11
11
  end
12
12
 
13
13
  def collect
14
- pipeline_id, pipeline = @agent.running_pipelines.first
15
- unless pipeline.nil?
16
- pipeline.collect_stats
14
+ pipelines = @agent.get_running_user_defined_pipelines
15
+ unless pipelines.nil?
16
+ pipelines.each {|_, pipeline|
17
+ unless pipeline.nil?
18
+ pipeline.collect_stats
19
+ end
20
+ }
17
21
  end
18
22
  end
19
23
  end
@@ -228,6 +228,14 @@ describe LogStash::Pipeline do
228
228
  pipeline = TestPipeline.new(test_config_with_filters, pipeline_settings_obj)
229
229
  pipeline.close
230
230
  end
231
+
232
+ it "should log each filtered event if config.debug is set to true" do
233
+ pipeline_settings_obj.set("config.debug", true)
234
+ pipeline = TestPipeline.new(test_config_with_filters, pipeline_settings_obj)
235
+ expect(logger).to receive(:debug).with(/filter received/, anything)
236
+ pipeline.filter_func([LogStash::Event.new])
237
+ pipeline.close
238
+ end
231
239
  end
232
240
 
233
241
  context "when there is no command line -w N set" do
@@ -1,6 +1,6 @@
1
1
  ---
2
- logstash: 5.6.3
3
- logstash-core: 5.6.3
2
+ logstash: 5.6.4
3
+ logstash-core: 5.6.4
4
4
  logstash-core-plugin-api: 2.1.12
5
5
 
6
6
  # Note: this file is copied to the root of logstash-core because its gemspec needs it when
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: logstash-core
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.6.3
4
+ version: 5.6.4
5
5
  platform: java
6
6
  authors:
7
7
  - Elastic
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-10-06 00:00:00.000000000 Z
11
+ date: 2017-10-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  requirement: !ruby/object:Gem::Requirement
@@ -594,6 +594,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
594
594
  - !ruby/object:Gem::Version
595
595
  version: '0'
596
596
  requirements:
597
+ - jar org.apache.logging.log4j:log4j-slf4j-impl, 2.6.2
597
598
  - jar org.apache.logging.log4j:log4j-api, 2.6.2
598
599
  - jar org.apache.logging.log4j:log4j-core, 2.6.2
599
600
  - jar com.fasterxml.jackson.core:jackson-core, 2.9.1