Open synFK opened 5 years ago
Okay, this is only true for the initial registering phase. Shutting the server down while being in the filtering phase leads to a handled exception which results in the desired tags. But: it also closes/resets the connection and does not open it on the next event, even if the server has started again.
So, if I get it right the only way to reestablish the connection is to restart Logstash. That is kind of inacceptable in production mode, isn't it?
I can not imagine, that we are the only ones with this issue. Or are the others like "Our database server simply never goes down."?
Whatever, I suggest a new mechanism, that handles database connection loss. Could be the options connection_retry_attempts
and connection_retry_attempts_wait_time
grabbed from Jdbc input plugin.
Please comment.
+1 I have got the exact same problem : the pipeline definitely stops processing events when the database server stops and restarts for nightly maintenance. Every morning I need to restart logstash.
@CedricP-AM there is a PR addressing this issue (https://github.com/logstash-plugins/logstash-filter-jdbc_streaming/pull/22). Also, you might have a look a this fork: https://github.com/synFK/logstash-filter-jdbc_streaming/tree/feature/retry_mechanism.
logstash (5.6.14 and 6.5.4) _logstash-filter-jdbcstreaming (1.0.4)
Hi there,
I get an error when connecting to a dababase server that refuses the connection. Unfortunately this error kills the whole pipeline and no further events are processed. In my understanding the tags from
tag_on_failure
should be applied in such a error case.