Reraise last error when getting DB connection
currently when there is a problem with configuration, the logging is insufficient, especially when running panko-dbsync command. Change-Id: I22ef74eb45f324fc6e374c4a3e03fbe9d7268eed
This commit is contained in:
parent
7dcd1350ba
commit
daa08ec939
|
@ -61,6 +61,7 @@ def get_connection_from_config(conf):
|
|||
retries = conf.database.max_retries
|
||||
|
||||
@tenacity.retry(
|
||||
reraise=True,
|
||||
wait=tenacity.wait_fixed(conf.database.retry_interval),
|
||||
stop=(tenacity.stop_after_attempt(retries) if retries >= 0
|
||||
else tenacity.stop_never)
|
||||
|
|
Loading…
Reference in New Issue