Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fails to upload files when logstash exits #15

Closed
wfhartford opened this issue Oct 18, 2017 · 2 comments
Closed

Fails to upload files when logstash exits #15

wfhartford opened this issue Oct 18, 2017 · 2 comments
Labels

Comments

@wfhartford
Copy link
Contributor

In situations where Logstash exits it is quite likely that the plugin will leave some files on disk, not uploaded to GCS. This is especially likely when large amounts of data is exported over a short execution.

My use case is exporting data from Elasticsearch to GCS using the logstash-input-elasticsearch plugin. This plugin will pull data out of Elasticsearch based on a configurable query. When all data from that query has been processed, Logstash will exit. In this case, it is almost certain that a significant amount of data will not be uploaded to GCS.

A related issue is covered in the Improvements TODO list in the header comment:

There's no recover method, so if logstash/plugin crashes, files may not be uploaded to GCS.

That description trivialities the issue by assuming that it only applies to crash situations, when in fact it applies any time Logstash exits including a user initiated shutdown and a successful completion. The export use case describe above transforms this from a potential minor problem to a fatal flaw.

@josephlewis42
Copy link
Contributor

I've added the ability to do this for the events in the queue as well as part of #21, once that's merged this should be closable.

@josephlewis42
Copy link
Contributor

Alright, this now works for both async and synchronous uploads. Synchronous uploads are still fully supported if you prefer to go that route.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants