diff --git a/lib/fluent/plugin/buffer/file_single_chunk.rb b/lib/fluent/plugin/buffer/file_single_chunk.rb index 2a08ce5740..9d2dc7c08b 100644 --- a/lib/fluent/plugin/buffer/file_single_chunk.rb +++ b/lib/fluent/plugin/buffer/file_single_chunk.rb @@ -266,7 +266,7 @@ def create_new_chunk(path, metadata, perm) # If other cases are possible, we will change erorr handling with proper classes. raise BufferOverflowError, "can't create buffer file for #{path}. Stop creating buffer files: error = #{e}" end - + @state = :unstaged @bytesize = 0 @commit_position = @chunk.pos # must be 0 @@ -306,7 +306,7 @@ def load_existing_enqueued_chunk(path) @state = :queued @bytesize = @chunk.size - @commit_position = @chunk.pos + @commit_position = @chunk.size end end end