fluentd 1.7.2-x64-mingw32 → 1.7.3-x64-mingw32

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of fluentd might be problematic. Click here for more details.

checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b1c23bb08691075a781ddfcfaeb1c2e689a6e62aef19d51d457a1557a7cf7d3e
4
- data.tar.gz: 582c1c5a436192d05905159d3504db1b97c972b0a48bfc3590c95070d857a570
3
+ metadata.gz: 558a99919aa105e4c6795da58021418045f44653503f5fea9548bd7d5e34f328
4
+ data.tar.gz: 4a096656de96248197fe1563309e87838fef716a5aae6dcc320d0d547b365065
5
5
  SHA512:
6
- metadata.gz: 50c8d0d17e6a7d9455e91c2aaffde32e6c0a599f7bd7c6ae9144fdf47562dd1480e17a7f3775e90b65339d3b60028880559f387e1d16d815fb52490cf7840009
7
- data.tar.gz: c428dcbb5be7bc8ef57d8c04c253510b1389f12e8f62db8924dc8cbe161ef6dc618e93fe1fc03d3cbe9370572c3a19060f188a5cf21f905bd4ad4b23b600f0b6
6
+ metadata.gz: 60bd1a1629e884935b0f1a7cde880071cd6c131e1ec82ec488877a926f74dc662e610b3af45f9df5e99264173168b464c05f100a30a709882ccaf290818f77d9
7
+ data.tar.gz: 3daf26b0e4f81abcbde67f2cf13b73b2856a84c336cea8e0a85a6b947418c418b52f57822b2ca11a351e4e9eeb30cc287241bd32c84dfc6c266692a78fba3b4b
@@ -1,5 +1,19 @@
1
1
  # v1.7
2
2
 
3
+ ## Release v1.7.3 - 2019/10/01
4
+
5
+ ### Enhancement
6
+
7
+ * in_syslog: Replace priority_key with severity_key
8
+ https://github.com/fluent/fluentd/pull/2636
9
+
10
+ ### Bug fixes
11
+
12
+ * out_forward: Fix nil error after purge obsoleted sockets in socket cache
13
+ https://github.com/fluent/fluentd/pull/2635
14
+ * fix typo in ChangeLog
15
+ https://github.com/fluent/fluentd/pull/2633
16
+
3
17
  ## Release v1.7.2 - 2019/09/19
4
18
 
5
19
  ### Enhancement
@@ -36,7 +50,7 @@
36
50
  https://github.com/fluent/fluentd/pull/2598
37
51
  * buf_file_single: fix duplicated path setting check
38
52
  https://github.com/fluent/fluentd/pull/2600
39
- * fix msgpack-ruby depedency to use recent feature
53
+ * fix msgpack-ruby dependency to use recent feature
40
54
  https://github.com/fluent/fluentd/pull/2606
41
55
 
42
56
 
@@ -640,7 +654,7 @@
640
654
 
641
655
  ## Release v1.0.0 - 2017/12/6
642
656
 
643
- See [CNCF announcment](https://www.cncf.io/blog/2017/12/06/fluentd-v1-0/) :)
657
+ See [CNCF announcement](https://www.cncf.io/blog/2017/12/06/fluentd-v1-0/) :)
644
658
 
645
659
  ### New features / Enhancements
646
660
 
@@ -910,7 +924,7 @@ See [CNCF announcment](https://www.cncf.io/blog/2017/12/06/fluentd-v1-0/) :)
910
924
  https://github.com/fluent/fluentd/pull/1492
911
925
  * parser: Allow escape sequence in Apache access log
912
926
  https://github.com/fluent/fluentd/pull/1479
913
- * config: Add actual value in the placholder error message
927
+ * config: Add actual value in the placeholder error message
914
928
  https://github.com/fluent/fluentd/pull/1497
915
929
  * log: Add Fluent::Log#<< to support some SDKs
916
930
  https://github.com/fluent/fluentd/pull/1478
@@ -1227,7 +1241,7 @@ See [CNCF announcment](https://www.cncf.io/blog/2017/12/06/fluentd-v1-0/) :)
1227
1241
  https://github.com/fluent/fluentd/pull/1067
1228
1242
  * filter_record_transformer: Fix to prevent overwriting reserved placeholder keys
1229
1243
  https://github.com/fluent/fluentd/pull/1176
1230
- * Migrate some build-in plugins into v0.14 API
1244
+ * Migrate some built-in plugins into v0.14 API
1231
1245
  https://github.com/fluent/fluentd/pull/1149
1232
1246
  https://github.com/fluent/fluentd/pull/1151
1233
1247
  * Update dependencies
@@ -56,7 +56,7 @@ module Fluent::Plugin
56
56
  23 => 'local7'
57
57
  }
58
58
 
59
- PRIORITY_MAP = {
59
+ SEVERITY_MAP = {
60
60
  0 => 'emerg',
61
61
  1 => 'alert',
62
62
  2 => 'crit',
@@ -91,8 +91,8 @@ module Fluent::Plugin
91
91
  config_param :resolve_hostname, :bool, default: nil
92
92
  desc 'The field name of source address of sender.'
93
93
  config_param :source_address_key, :string, default: nil
94
- desc 'The field name of the priority.'
95
- config_param :priority_key, :string, default: nil
94
+ desc 'The field name of the severity.'
95
+ config_param :severity_key, :string, default: nil, alias: :priority_key
96
96
  desc 'The field name of the facility.'
97
97
  config_param :facility_key, :string, default: nil
98
98
 
@@ -119,6 +119,10 @@ module Fluent::Plugin
119
119
 
120
120
  super
121
121
 
122
+ if conf.has_key?('priority_key')
123
+ log.warn "priority_key is deprecated. Use severity_key instead"
124
+ end
125
+
122
126
  @use_default = false
123
127
 
124
128
  @parser = parser_create
@@ -233,14 +237,14 @@ module Fluent::Plugin
233
237
 
234
238
  pri ||= record.delete('pri')
235
239
  facility = FACILITY_MAP[pri >> 3]
236
- priority = PRIORITY_MAP[pri & 0b111]
240
+ severity = SEVERITY_MAP[pri & 0b111]
237
241
 
238
- record[@priority_key] = priority if @priority_key
242
+ record[@severity_key] = severity if @severity_key
239
243
  record[@facility_key] = facility if @facility_key
240
244
  record[@source_address_key] = sock.remote_addr if @source_address_key
241
245
  record[@source_hostname_key] = sock.remote_host if @source_hostname_key
242
246
 
243
- tag = "#{@tag}.#{facility}.#{priority}"
247
+ tag = "#{@tag}.#{facility}.#{severity}"
244
248
  emit(tag, time, record)
245
249
  end
246
250
  rescue => e
@@ -81,7 +81,9 @@ module Fluent::Plugin
81
81
  end
82
82
  end
83
83
  end
84
- @available_sockets = @available_sockets.select { |_, v| !v.empty? }
84
+
85
+ # reuse same object (@available_sockets)
86
+ @available_sockets.reject! { |_, v| v.empty? }
85
87
 
86
88
  sockets += @inactive_sockets
87
89
  @inactive_sockets.clear
@@ -16,6 +16,6 @@
16
16
 
17
17
  module Fluent
18
18
 
19
- VERSION = '1.7.2'
19
+ VERSION = '1.7.3'
20
20
 
21
21
  end
@@ -5,7 +5,7 @@ require 'timecop'
5
5
 
6
6
  class SocketCacheTest < Test::Unit::TestCase
7
7
  sub_test_case 'checkout_or' do
8
- test 'when gived key does not exist' do
8
+ test 'when given key does not exist' do
9
9
  c = Fluent::Plugin::ForwardOutput::SocketCache.new(10, $log)
10
10
  sock = mock!.open { 'socket' }.subject
11
11
  assert_equal('socket', c.checkout_or('key') { sock.open })
@@ -38,6 +38,16 @@ class SocketCacheTest < Test::Unit::TestCase
38
38
  sock = mock!.open { new_sock }.subject
39
39
  assert_equal(new_sock, c.checkout_or('key') { sock.open })
40
40
  end
41
+
42
+ test 'reuse same hash object after calling purge_obsolete_socks' do
43
+ c = Fluent::Plugin::ForwardOutput::SocketCache.new(10, $log)
44
+ c.checkout_or('key') { 'socket' }
45
+ c.purge_obsolete_socks
46
+
47
+ assert_nothing_raised(NoMethodError) do
48
+ c.checkout_or('key') { 'new socket' }
49
+ end
50
+ end
41
51
  end
42
52
 
43
53
  sub_test_case 'checkin' do
@@ -495,7 +495,7 @@ class BufferFileChunkTest < Test::Unit::TestCase
495
495
  end
496
496
  end
497
497
 
498
- test 'ensure to remove metadata file if #write_metadata raise an error becuase of disk full' do
498
+ test 'ensure to remove metadata file if #write_metadata raise an error because of disk full' do
499
499
  chunk_path = File.join(@chunkdir, 'test.*.log')
500
500
  stub(Fluent::UniqueId).hex(anything) { 'id' } # to fix chunk id
501
501
 
@@ -217,11 +217,15 @@ EOS
217
217
  compare_test_result(d.events, tests, {host: host})
218
218
  end
219
219
 
220
- def test_msg_size_with_priority_key
221
- d = create_driver([CONFIG, 'priority_key priority'].join("\n"))
220
+ data(
221
+ severity_key: 'severity_key',
222
+ priority_key: 'priority_key',
223
+ )
224
+ def test_msg_size_with_severity_key(param_name)
225
+ d = create_driver([CONFIG, "#{param_name} severity"].join("\n"))
222
226
  tests = create_test_case
223
227
 
224
- priority = 'info'
228
+ severity = 'info'
225
229
  d.run(expect_emits: 2) do
226
230
  u = UDPSocket.new
227
231
  u.connect('127.0.0.1', PORT)
@@ -231,7 +235,7 @@ EOS
231
235
  end
232
236
 
233
237
  assert(d.events.size > 0)
234
- compare_test_result(d.events, tests, {priority: priority})
238
+ compare_test_result(d.events, tests, {severity: severity})
235
239
  end
236
240
 
237
241
  def test_msg_size_with_facility_key
@@ -311,7 +315,7 @@ EOS
311
315
  assert_equal(options[:host], events[i][2]['source_host']) if options[:host]
312
316
  assert_equal(options[:address], events[i][2]['source_address']) if options[:address]
313
317
  assert_equal(options[:hostname], events[i][2]['source_hostname']) if options[:hostname]
314
- assert_equal(options[:priority], events[i][2]['priority']) if options[:priority]
318
+ assert_equal(options[:severity], events[i][2]['severity']) if options[:severity]
315
319
  assert_equal(options[:facility], events[i][2]['facility']) if options[:facility]
316
320
  }
317
321
  end
@@ -1112,7 +1112,7 @@ class BufferedOutputTest < Test::Unit::TestCase
1112
1112
  assert_equal(0, @i.write_count)
1113
1113
 
1114
1114
  Timecop.freeze(Time.parse('2019-02-09 00:00:12 +0900'))
1115
- # wirte should be called in few seconds since
1115
+ # write should be called in few seconds since
1116
1116
  # running interval of enque thread is timekey_wait / 11.0.
1117
1117
  waiting(5){ sleep 0.1 until @i.write_count == 1 }
1118
1118
  end
@@ -710,7 +710,7 @@ EOC
710
710
  end
711
711
  end
712
712
 
713
- test 'raises configuration error for worker id collisions on multi workers syntax when multi avaliable worker_ids are left' do
713
+ test 'raises configuration error for worker id collisions on multi workers syntax when multi available worker_ids are left' do
714
714
  errmsg = "specified worker_id<1> collisions is detected on <worker> directive. Available worker id(s): [2, 3]"
715
715
  assert_raise Fluent::ConfigError.new(errmsg) do
716
716
  conf = <<-EOC
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fluentd
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.7.2
4
+ version: 1.7.3
5
5
  platform: x64-mingw32
6
6
  authors:
7
7
  - Sadayuki Furuhashi
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-09-20 00:00:00.000000000 Z
11
+ date: 2019-10-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: msgpack