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

Fix state removal and sending empty lines #2105

Merged
merged 2 commits into from
Jul 27, 2016

Conversation

ruflin
Copy link
Contributor

@ruflin ruflin commented Jul 27, 2016

State Removal

With a very low scan_frequency it could potentially happen, that a state of a finished harvester was overwritten by the prospector which lead to the problem, that the state was never set to Finished. This is now fixed in that the prospector only sends a state when the state is set to Finished.

Sending empty lines

Empty lines were still sent as the byte check was set to 0 and with the newline char it was always at least 1. The tests passed because filebeat was shutdown before the last line was written. Tests were now improved to tests both cases.

Example failed build: http://build-eu-00.elastic.co/job/Beats-PR/2577/

@ruflin ruflin added in progress Pull request is currently in progress. Filebeat Filebeat labels Jul 27, 2016
= State Removal

With a very low scan_frequency it could potentially happen, that a state of a finished harvester was overwritten by the prospector which lead to the problem, that the state was never set to Finished. This is now fixed in that the prospector only sends a state when the state is set to Finished.

= Sending empty lines

Empty lines were still sent as the byte check was set to 0 and with the newline char it was always at least 1. The tests passed because filebeat was shutdown before the last line was written. Tests were now improved to tests both cases.
@ruflin ruflin force-pushed the fix-flaky-filebeat-test branch from 3d37cf5 to 4d3ee0e Compare July 27, 2016 07:34
@ruflin ruflin changed the title Send state update only after file was closed Fix state removal and sending empty lines Jul 27, 2016
@ruflin ruflin added review and removed in progress Pull request is currently in progress. labels Jul 27, 2016
@tsg tsg merged commit ed21869 into elastic:master Jul 27, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants