diff --git a/lib/fluent/engine.rb b/lib/fluent/engine.rb index d5551221ae..609f924774 100644 --- a/lib/fluent/engine.rb +++ b/lib/fluent/engine.rb @@ -22,6 +22,7 @@ require 'fluent/time' require 'fluent/system_config' require 'fluent/plugin' +require 'fluent/fluent_log_event_router' module Fluent class EngineClass @@ -30,19 +31,14 @@ class EngineClass def initialize @root_agent = nil - @default_loop = nil @engine_stopped = false @_worker_id = nil - @log_event_router = nil - @log_emit_thread = nil - @log_event_loop_stop = false - @log_event_loop_graceful_stop = false - @log_event_queue = [] @log_event_verbose = false - @suppress_config_dump = false + @without_source = false + @fluent_log_event_router = nil @system_config = SystemConfig.new @dry_run_mode = false @@ -50,13 +46,7 @@ def initialize MAINLOOP_SLEEP_INTERVAL = 0.3 - MATCH_CACHE_SIZE = 1024 - LOG_EMIT_INTERVAL = 0.1 - - attr_reader :root_agent - attr_reader :matches, :sources - attr_reader :system_config - + attr_reader :root_agent, :system_config attr_accessor :dry_run_mode def init(system_config) @@ -116,43 +106,14 @@ def run_configure(conf) end def configure(conf) - # plugins / configuration dumps - Gem::Specification.find_all.select{|x| x.name =~ /^fluent(d|-(plugin|mixin)-.*)$/}.each do |spec| - $log.info :worker0, "gem '#{spec.name}' version '#{spec.version}'" - end - @root_agent.configure(conf) - begin - log_event_agent = @root_agent.find_label(Fluent::Log::LOG_EVENT_LABEL) - log_event_router = log_event_agent.event_router - - # suppress mismatched tags only for