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

check connection status befor the put_copy_end method #36

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

pigi-spm
Copy link

Hi,

this bug-fix is due to an error after DB connection, if you use BUFFER in fluentd configuration file with this plugin.
You have this problem if the connection to DB is already established and after the connection interruption the plugin tries to use the put_copy_end method to send the end-of-data indication to the server, but if the connection doesn't exists or it's was interrupted, plugin can't send request and generates an error.
At this point the only possibility to restore the connection is to restart fluentd process so that the connection is re-established with the DB and the data is send again.

The if on code checks if you have a valid connection or not, if not it resets the connection immediately.
After many tests, it seems to work correctly with the option of Buffer.

image

Best regards

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

Successfully merging this pull request may close these issues.

1 participant