fluentd 0.14.24 → 0.14.25
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 +4 -4
- data/CHANGELOG.md +16 -0
- data/lib/fluent/plugin/out_forward.rb +3 -3
- data/lib/fluent/plugin/output.rb +8 -4
- data/lib/fluent/root_agent.rb +13 -4
- data/lib/fluent/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f484a644308a8845fea9a1d1c7e5dffcc1660de0
|
4
|
+
data.tar.gz: eb06fee3d5f392a76ace5fdb2e60f3be250d5249
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 91d09e99c7c0745af5f578f27e449f82535f763cba786acf8997ca0994166b2b2f481f99fa4236d5b799bdc89948c8d9d447aba879d4e63b6a9744cd56b55f02
|
7
|
+
data.tar.gz: 3c287549f1d5038f58c039ee082fd69661c28400b4d47562039bd229371a6af48d1b3bbd47965664ead892d95077fae4336e4b91b7ff51385d9c785b57b2935e
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,19 @@
|
|
1
|
+
# v1.0
|
2
|
+
|
3
|
+
## Release v1.0.0.rc1/v0.14.25 - 2017/11/29
|
4
|
+
|
5
|
+
### New features / Enhancements
|
6
|
+
|
7
|
+
* Disable tracepoint feature to omit unnecessary insts
|
8
|
+
https://github.com/fluent/fluentd/pull/1764
|
9
|
+
|
10
|
+
### Bug fixes
|
11
|
+
|
12
|
+
* out_forward: Don't update retry state when failed to get ack response.
|
13
|
+
https://github.com/fluent/fluentd/pull/1686
|
14
|
+
* plugin: Combine before_shutdown and shutdown call in one sequence.
|
15
|
+
https://github.com/fluent/fluentd/pull/1763
|
16
|
+
|
1
17
|
# v0.14
|
2
18
|
|
3
19
|
## Release v0.14.24 - 2017/11/24
|
@@ -433,7 +433,7 @@ module Fluent::Plugin
|
|
433
433
|
if raw_data.empty?
|
434
434
|
log.warn "destination node closed the connection. regard it as unavailable.", host: info.node.host, port: info.node.port
|
435
435
|
info.node.disable!
|
436
|
-
rollback_write(info.chunk_id)
|
436
|
+
rollback_write(info.chunk_id, update_retry: false)
|
437
437
|
return nil
|
438
438
|
else
|
439
439
|
unpacker.feed(raw_data)
|
@@ -442,7 +442,7 @@ module Fluent::Plugin
|
|
442
442
|
if res['ack'] != info.chunk_id_base64
|
443
443
|
# Some errors may have occured when ack and chunk id is different, so send the chunk again.
|
444
444
|
log.warn "ack in response and chunk id in sent data are different", chunk_id: dump_unique_id_hex(info.chunk_id), ack: res['ack']
|
445
|
-
rollback_write(info.chunk_id)
|
445
|
+
rollback_write(info.chunk_id, update_retry: false)
|
446
446
|
return nil
|
447
447
|
else
|
448
448
|
log.trace "got a correct ack response", chunk_id: dump_unique_id_hex(info.chunk_id)
|
@@ -483,7 +483,7 @@ module Fluent::Plugin
|
|
483
483
|
log.warn "no response from node. regard it as unavailable.", host: info.node.host, port: info.node.port
|
484
484
|
info.node.disable!
|
485
485
|
info.sock.close rescue nil
|
486
|
-
rollback_write(info.chunk_id)
|
486
|
+
rollback_write(info.chunk_id, update_retry: false)
|
487
487
|
else
|
488
488
|
sockets << info.sock
|
489
489
|
new_list << info
|
data/lib/fluent/plugin/output.rb
CHANGED
@@ -226,7 +226,7 @@ module Fluent
|
|
226
226
|
|
227
227
|
singleton_class.module_eval do
|
228
228
|
define_method(:commit_write){ |chunk_id| @primary_instance.commit_write(chunk_id, delayed: delayed_commit, secondary: true) }
|
229
|
-
define_method(:rollback_write){ |chunk_id| @primary_instance.rollback_write(chunk_id) }
|
229
|
+
define_method(:rollback_write){ |chunk_id, update_retry: true| @primary_instance.rollback_write(chunk_id, update_retry) }
|
230
230
|
end
|
231
231
|
end
|
232
232
|
|
@@ -991,7 +991,9 @@ module Fluent
|
|
991
991
|
end
|
992
992
|
end
|
993
993
|
|
994
|
-
|
994
|
+
# update_retry parameter is for preventing busy loop by async write
|
995
|
+
# We will remove this parameter by re-design retry_state management between threads.
|
996
|
+
def rollback_write(chunk_id, update_retry: true)
|
995
997
|
# This API is to rollback chunks explicitly from plugins.
|
996
998
|
# 3rd party plugins can depend it on automatic rollback of #try_rollback_write
|
997
999
|
@dequeued_chunks_mutex.synchronize do
|
@@ -1002,8 +1004,10 @@ module Fluent
|
|
1002
1004
|
# in many cases, false can be just ignored
|
1003
1005
|
if @buffer.takeback_chunk(chunk_id)
|
1004
1006
|
@counters_monitor.synchronize{ @rollback_count += 1 }
|
1005
|
-
|
1006
|
-
|
1007
|
+
if update_retry
|
1008
|
+
primary = @as_secondary ? @primary_instance : self
|
1009
|
+
primary.update_retry_state(chunk_id, @as_secondary)
|
1010
|
+
end
|
1007
1011
|
true
|
1008
1012
|
else
|
1009
1013
|
false
|
data/lib/fluent/root_agent.rb
CHANGED
@@ -212,7 +212,6 @@ module Fluent
|
|
212
212
|
|
213
213
|
lifecycle_unsafe_sequence = ->(method, checker) {
|
214
214
|
operation = case method
|
215
|
-
when :before_shutdown then "preparing shutdown"
|
216
215
|
when :shutdown then "shutting down"
|
217
216
|
when :close then "closing"
|
218
217
|
else
|
@@ -228,11 +227,23 @@ module Fluent
|
|
228
227
|
Thread.current.abort_on_exception = true
|
229
228
|
begin
|
230
229
|
if method == :shutdown
|
230
|
+
# To avoid Input#shutdown and Output#before_shutdown mismatch problem, combine before_shutdown and shutdown call in one sequence.
|
231
|
+
# The problem is in_tail flushes buffered multiline in shutdown but output's flush_at_shutdown is invoked in before_shutdown
|
232
|
+
operation = "preparing shutdown" # for logging
|
233
|
+
log.debug "#{operation} #{kind} plugin", type: Plugin.lookup_type_from_class(instance.class), plugin_id: instance.plugin_id
|
234
|
+
begin
|
235
|
+
instance.send(:before_shutdown) unless instance.send(:before_shutdown?)
|
236
|
+
rescue Exception => e
|
237
|
+
log.warn "unexpected error while #{operation} on #{kind} plugin", plugin: instance.class, plugin_id: instance.plugin_id, error: e
|
238
|
+
log.warn_backtrace
|
239
|
+
end
|
240
|
+
operation = "shutting down"
|
231
241
|
log.info "#{operation} #{kind} plugin", type: Plugin.lookup_type_from_class(instance.class), plugin_id: instance.plugin_id
|
242
|
+
instance.send(:shutdown) unless instance.send(:shutdown?)
|
232
243
|
else
|
233
244
|
log.debug "#{operation} #{kind} plugin", type: Plugin.lookup_type_from_class(instance.class), plugin_id: instance.plugin_id
|
245
|
+
instance.send(method) unless instance.send(checker)
|
234
246
|
end
|
235
|
-
instance.send(method) unless instance.send(checker)
|
236
247
|
rescue Exception => e
|
237
248
|
log.warn "unexpected error while #{operation} on #{kind} plugin", plugin: instance.class, plugin_id: instance.plugin_id, error: e
|
238
249
|
log.warn_backtrace
|
@@ -245,8 +256,6 @@ module Fluent
|
|
245
256
|
lifecycle_safe_sequence.call(:stop, :stopped?)
|
246
257
|
|
247
258
|
# before_shutdown does force_flush for output plugins: it should block, so it's unsafe operation
|
248
|
-
lifecycle_unsafe_sequence.call(:before_shutdown, :before_shutdown?)
|
249
|
-
|
250
259
|
lifecycle_unsafe_sequence.call(:shutdown, :shutdown?)
|
251
260
|
|
252
261
|
lifecycle_safe_sequence.call(:after_shutdown, :after_shutdown?)
|
data/lib/fluent/version.rb
CHANGED
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: 0.14.
|
4
|
+
version: 0.14.25
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Sadayuki Furuhashi
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-11-
|
11
|
+
date: 2017-11-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: msgpack
|