Skip to content

Commit

Permalink
for readability
Browse files Browse the repository at this point in the history
  • Loading branch information
tagomoris committed May 9, 2016
1 parent b31851c commit 161ecbb
Showing 1 changed file with 44 additions and 44 deletions.
88 changes: 44 additions & 44 deletions lib/fluent/compat/output.rb
Original file line number Diff line number Diff line change
Expand Up @@ -187,20 +187,20 @@ def support_in_v12_style?(feature)

config_param :flush_at_shutdown, :bool, default: true

PARAMS_MAP = [
["buffer_type", "@type"],
["num_threads", "flush_threads"],
["flush_interval", "flush_interval"],
["try_flush_interval", "flush_thread_interval"],
["queued_chunk_flush_interval", "flush_burst_interval"],
["disable_retry_limit", "retry_forever"],
["retry_limit", "retry_max_times"],
["max_retry_wait", "retry_max_interval"],
["buffer_chunk_limit", "chunk_bytes_limit"],
["buffer_queue_limit", "queue_length_limit"],
["buffer_queue_full_action", nil], # TODO: implement this on fluent/plugin/buffer
["flush_at_shutdown", "flush_at_shutdown"],
]
PARAMS_MAP = {
"buffer_type" => "@type",
"num_threads" => "flush_threads",
"flush_interval" => "flush_interval",
"try_flush_interval" => "flush_thread_interval",
"queued_chunk_flush_interval" => "flush_burst_interval",
"disable_retry_limit" => "retry_forever",
"retry_limit" => "retry_max_times",
"max_retry_wait" => "retry_max_interval",
"buffer_chunk_limit" => "chunk_bytes_limit",
"buffer_queue_limit" => "queue_length_limit",
"buffer_queue_full_action" => nil, # TODO: implement this on fluent/plugin/buffer
"flush_at_shutdown" => "flush_at_shutdown",
}

def configure(conf)
bufconf = CompatOutputUtils.buffer_section(conf)
Expand Down Expand Up @@ -316,20 +316,20 @@ def support_in_v12_style?(feature)

config_set_default :time_as_integer, true

PARAMS_MAP = [
["buffer_type", "@type"],
["num_threads", "flush_threads"],
["flush_interval", "flush_interval"],
["try_flush_interval", "flush_thread_interval"],
["queued_chunk_flush_interval", "flush_burst_interval"],
["disable_retry_limit", "retry_forever"],
["retry_limit", "retry_max_times"],
["max_retry_wait", "retry_max_interval"],
["buffer_chunk_limit", "chunk_bytes_limit"],
["buffer_queue_limit", "queue_length_limit"],
["buffer_queue_full_action", nil], # TODO: implement this on fluent/plugin/buffer
["flush_at_shutdown", "flush_at_shutdown"],
]
PARAMS_MAP = {
"buffer_type" => "@type",
"num_threads" => "flush_threads",
"flush_interval" => "flush_interval",
"try_flush_interval" => "flush_thread_interval",
"queued_chunk_flush_interval" => "flush_burst_interval",
"disable_retry_limit" => "retry_forever",
"retry_limit" => "retry_max_times",
"max_retry_wait" => "retry_max_interval",
"buffer_chunk_limit" => "chunk_bytes_limit",
"buffer_queue_limit" => "queue_length_limit",
"buffer_queue_full_action" => nil, # TODO: implement this on fluent/plugin/buffer
"flush_at_shutdown" => "flush_at_shutdown",
}

def configure(conf)
bufconf = CompatOutputUtils.buffer_section(conf)
Expand Down Expand Up @@ -436,22 +436,22 @@ def support_in_v12_style?(feature)
config_set_default :@type, 'file2'
end

PARAMS_MAP = [
["buffer_type", "@type"],
["buffer_path", "path"],
["num_threads", "flush_threads"],
["flush_interval", "flush_interval"],
["try_flush_interval", "flush_thread_interval"],
["queued_chunk_flush_interval", "flush_burst_interval"],
["disable_retry_limit", "retry_forever"],
["retry_limit", "retry_max_times"],
["max_retry_wait", "retry_max_interval"],
["buffer_chunk_limit", "chunk_bytes_limit"],
["buffer_queue_limit", "queue_length_limit"],
["buffer_queue_full_action", nil], # TODO: implement this on fluent/plugin/buffer
["flush_at_shutdown", "flush_at_shutdown"],
["time_slice_wait", "timekey_wait"],
]
PARAMS_MAP = {
"buffer_type" => "@type",
"buffer_path" => "path",
"num_threads" => "flush_threads",
"flush_interval" => "flush_interval",
"try_flush_interval" => "flush_thread_interval",
"queued_chunk_flush_interval" => "flush_burst_interval",
"disable_retry_limit" => "retry_forever",
"retry_limit" => "retry_max_times",
"max_retry_wait" => "retry_max_interval",
"buffer_chunk_limit" => "chunk_bytes_limit",
"buffer_queue_limit" => "queue_length_limit",
"buffer_queue_full_action" => nil, # TODO: implement this on fluent/plugin/buffer
"flush_at_shutdown" => "flush_at_shutdown",
"time_slice_wait" => "timekey_wait",
}

def initialize
super
Expand Down

0 comments on commit 161ecbb

Please sign in to comment.