Sha256: 197631388862d96b5b40c6a84fb5d252a8da0eb9f3ef0795c3512868ccc1b1c3
Contents?: true
Size: 579 Bytes
Versions: 49
Compression:
Stored size: 579 Bytes
Contents
# encoding: utf-8 require "logstash/outputs/s3/size_rotation_policy" require "logstash/outputs/s3/time_rotation_policy" module LogStash module Outputs class S3 class SizeAndTimeRotationPolicy def initialize(file_size, time_file) @size_strategy = SizeRotationPolicy.new(file_size) @time_strategy = TimeRotationPolicy.new(time_file) end def rotate?(file) @size_strategy.rotate?(file) || @time_strategy.rotate?(file) end def needs_periodic? true end end end end end
Version data entries
49 entries across 49 versions & 3 rubygems