Skip to content

Commit

Permalink
fix bug for variable "timekey" and others
Browse files Browse the repository at this point in the history
  • Loading branch information
tagomoris committed May 24, 2016
1 parent c3c5da1 commit a72a636
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/fluent/plugin/output.rb
Original file line number Diff line number Diff line change
Expand Up @@ -915,10 +915,10 @@ def enqueue_thread_run
end

if @chunk_key_time
timekey = @buffer_config.timekey
timekey_unit = @buffer_config.timekey
timekey_wait = @buffer_config.timekey_wait
current_timekey = now_int - now_int % timekey
@buffer.enqueue_all{ |metadata, chunk| metadata.timekey < current_time_range && metadata.timekey + timekey + timekey_wait <= now_int }
current_timekey = now_int - now_int % timekey_unit
@buffer.enqueue_all{ |metadata, chunk| metadata.timekey < current_timekey && metadata.timekey + timekey_unit + timekey_wait <= now_int }
end
rescue => e
log.error "unexpected error while checking flushed chunks. ignored.", plugin_id: plugin_id, error_class: e.class, error: e
Expand Down

0 comments on commit a72a636

Please sign in to comment.