Class: Fluent::ObjectBufferedOutput
- Inherits:
-
BufferedOutput
- Object
- Output
- BufferedOutput
- Fluent::ObjectBufferedOutput
- Defined in:
- lib/fluent/output.rb
Direct Known Subclasses
Defined Under Namespace
Modules: BufferedEventStreamMixin
Instance Attribute Summary
Attributes included from Configurable
Instance Method Summary collapse
- #emit(tag, es, chain) ⇒ Object
-
#initialize ⇒ ObjectBufferedOutput
constructor
A new instance of ObjectBufferedOutput.
- #write(chunk) ⇒ Object
Methods inherited from BufferedOutput
#before_shutdown, #calc_retry_wait, #configure, #enqueue_buffer, #flush_secondary, #force_flush, #format_stream, #shutdown, #start, #submit_flush, #try_flush, #write_abort
Methods inherited from Output
#configure, #secondary_init, #shutdown, #start
Methods included from PluginId
#configure, #plugin_id, #require_id
Methods included from Configurable
Constructor Details
#initialize ⇒ ObjectBufferedOutput
Returns a new instance of ObjectBufferedOutput.
401 402 403 |
# File 'lib/fluent/output.rb', line 401 def initialize super end |
Instance Method Details
#emit(tag, es, chain) ⇒ Object
405 406 407 408 409 410 411 |
# File 'lib/fluent/output.rb', line 405 def emit(tag, es, chain) data = es.to_msgpack_stream key = tag if @buffer.emit(key, data, chain) submit_flush end end |
#write(chunk) ⇒ Object
429 430 431 432 |
# File 'lib/fluent/output.rb', line 429 def write(chunk) chunk.extend(BufferedEventStreamMixin) write_objects(chunk.key, chunk) end |