mirror of
https://github.com/elastic/logstash.git
synced 2025-04-24 06:37:19 -04:00
Add teardown to flush elasticsearch on agent shutdown
Prior to this, some events could be lost if logstash was shutdown.
This commit is contained in:
parent
0f3dff2e1f
commit
bbb4f72557
1 changed files with 4 additions and 0 deletions
|
@ -334,4 +334,8 @@ class LogStash::Outputs::ElasticSearch < LogStash::Outputs::Base
|
|||
# retried.
|
||||
end # def flush
|
||||
|
||||
def teardown
|
||||
buffer_flush(:final => true)
|
||||
end
|
||||
|
||||
end # class LogStash::Outputs::Elasticsearch
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue