Class: LogStash::Outputs::CassandraOutput
- Inherits:
-
Base
- Object
- Base
- LogStash::Outputs::CassandraOutput
- Defined in:
- lib/logstash/outputs/cassandra.rb
Instance Method Summary collapse
- #close ⇒ Object
- #flush ⇒ Object
- #multi_receive(events) ⇒ Object
- #receive(event) ⇒ Object
- #register ⇒ Object
- #teardown ⇒ Object
Instance Method Details
#close ⇒ Object
135 136 137 |
# File 'lib/logstash/outputs/cassandra.rb', line 135 def close @buffer.stop end |
#flush ⇒ Object
139 140 141 |
# File 'lib/logstash/outputs/cassandra.rb', line 139 def flush @buffer.flush end |
#multi_receive(events) ⇒ Object
125 126 127 128 129 |
# File 'lib/logstash/outputs/cassandra.rb', line 125 def multi_receive(events) events.each_slice(@flush_size) do |slice| @safe_submitter.submit(slice.map {|event| @event_parser.parse(event) }) end end |
#receive(event) ⇒ Object
121 122 123 |
# File 'lib/logstash/outputs/cassandra.rb', line 121 def receive(event) @buffer << @event_parser.parse(event) end |
#register ⇒ Object
115 116 117 118 119 |
# File 'lib/logstash/outputs/cassandra.rb', line 115 def register setup_event_parser setup_safe_submitter setup_buffer_and_handler end |
#teardown ⇒ Object
131 132 133 |
# File 'lib/logstash/outputs/cassandra.rb', line 131 def teardown close end |