Class: Fluent::UnixInput

Inherits:
StreamInput show all
Defined in:
lib/fluent/plugin/in_stream.rb

Instance Attribute Summary

Attributes included from Configurable

#config

Instance Method Summary collapse

Methods inherited from StreamInput

#initialize, #run, #shutdown, #start

Methods inherited from Input

#initialize, #shutdown, #start

Methods included from PluginId

#plugin_id, #require_id

Methods included from Configurable

included, #initialize

Constructor Details

This class inherits a constructor from Fluent::StreamInput

Instance Method Details

#configure(conf) ⇒ Object



183
184
185
186
# File 'lib/fluent/plugin/in_stream.rb', line 183

def configure(conf)
  super
  #$log.warn "'unix' input is obsoleted and will be removed. Use 'forward' instead."
end

#listenObject



188
189
190
191
192
193
194
195
# File 'lib/fluent/plugin/in_stream.rb', line 188

def listen
  if File.exist?(@path)
    File.unlink(@path)
  end
  FileUtils.mkdir_p File.dirname(@path)
  $log.debug "listening fluent socket on #{@path}"
  Coolio::UNIXServer.new(@path, Handler, method(:on_message))
end