Class: LogStashLogger::Device::UDP
- Inherits:
-
Socket
- Object
- Base
- Connectable
- Socket
- LogStashLogger::Device::UDP
- Defined in:
- lib/logstash-logger/device/udp.rb
Constant Summary
Constants inherited from Socket
Instance Attribute Summary
Attributes inherited from Socket
Attributes inherited from Connectable
Attributes inherited from Base
Instance Method Summary collapse
Methods inherited from Socket
#initialize, #unrecoverable_error?
Methods inherited from Connectable
#close, #connected?, #flush, #initialize, #on_full_buffer_receive, #reconnect, #reset, #to_io, #with_connection, #write, #write_batch, #write_one
Methods included from Buffer
#buffer_flush, #buffer_full?, #buffer_initialize, #buffer_receive, #reset_buffer
Methods inherited from Base
#close, #close!, #flush, #initialize, #reset, #to_io, #unrecoverable_error?, #write, #write_batch, #write_one
Constructor Details
This class inherits a constructor from LogStashLogger::Device::Socket
Instance Method Details
#connect ⇒ Object
4 5 6 7 8 9 |
# File 'lib/logstash-logger/device/udp.rb', line 4 def connect @io = UDPSocket.new.tap do |socket| socket.connect(@host, @port) socket.sync = sync unless sync.nil? end end |