-
Notifications
You must be signed in to change notification settings - Fork 189
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
Retry Establishing Connection if it Fails #91
Comments
Hi, I'm using the jdbc plug-in as well and ran into the same issue. hoping the retry_count or connection parameter will kick-in every interval in the schedule. |
+1 for this. Here I'm hitting an issue that I want my logstash to start on server boot, but if the source DB isn't up yet it bombs out
Would be great if there were an option to retry, or not abort on error and just retry at the next For the moment I've worked around it by placing this in the line before kicking off logstash. It's not pretty but it basically wait for the listener to be up checking it every 5 seconds. rc=1;while [ $rc -eq 1 ]; do nc -vz localhost 1521 > /dev/null; rc=$?;echo $rc;sleep 5;done |
This seems like a bug to me. I don't believe other inputs will cause logstash to exit. "file" certainly doesn't if the file doesn't exist. EDIT: I think this is actually a similar situation to #76 |
I'm currently using the jdbc plug-in to ingest data from an Oracle database into Elasticsearch every hour on the hour. I've noticed that sometimes the data fails to be ingested and when I check the logstash log file I see an error similar to the one below:
{:timestamp=>"2015-11-28T08:00:00.309000-0500", :message=>"Exception when executing JDBC query", :exception=>#<Sequel::DatabaseDisconnectError: Java::JavaSql::SQLRecoverableException: Closed Connection>, :level=>:warn}
It appears the logstash input failed because of a connection error, and I think it would be helpful to add a
retry_count
parameter and corresponding functionality so logstash will retry establishing the connectionretry_count
times. So, for example, if it fails the first time logstash might try again two more times. Thanks!The text was updated successfully, but these errors were encountered: