This repository has been archived by the owner on Feb 20, 2023. It is now read-only.
Add configurable timeout to run db script #1550
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
When running the database through our python scripts there is a hardcoded timeout of 600 seconds. After waiting for the DB to startup for 600 seconds the script times out and returns an error.
I think for some use cases 10 minutes is a bit excessive to wait and we may want to timeout much sooner. To solve this I added an optional timeout parameter that defaults to 600 seconds. All existing scripts will be unchanged, but those in the future who want to set a smaller timeout can do that.
Sorry for the formatting changes, I format all the files I'm working on out of habit. If it's an issue I can go through and revert all the formatting changes.