class LogStash::Outputs::Qingstor::RotationPolicy::Policy

Public Instance Methods

name() click to toggle source
# File lib/logstash/outputs/qingstor/rotation_policy.rb, line 10
def name
  self.class.name.split('::').last.downcase
end
needs_periodic?() click to toggle source
# File lib/logstash/outputs/qingstor/rotation_policy.rb, line 14
def needs_periodic?
  true
end
positive_check(*arg) click to toggle source
# File lib/logstash/outputs/qingstor/rotation_policy.rb, line 18
def positive_check(*arg)
  arg.each do |x|
    raise(LogStash::ConfigurationError,
          "#{name} policy needs positive arguments") if x <= 0
  end
end