mirror of
https://github.com/puppetlabs/vmpooler.git
synced 2026-01-26 01:58:41 -05:00
(POOLER-184) Pool manager retry and exit on failure
Adding a reconnect retry for redis, which by default would retry 10 times, for a total wait time of ~80 seconds
This commit is contained in:
parent
bdf77a9e33
commit
a35d66c606
3 changed files with 14 additions and 5 deletions
|
|
@ -9,6 +9,7 @@ redis_port = config[:redis]['port']
|
|||
redis_password = config[:redis]['password']
|
||||
redis_connection_pool_size = config[:redis]['connection_pool_size']
|
||||
redis_connection_pool_timeout = config[:redis]['connection_pool_timeout']
|
||||
redis_reconnect_attempts = config[:redis]['reconnect_attempts'] || 10
|
||||
logger_file = config[:config]['logfile']
|
||||
|
||||
logger = Vmpooler::Logger.new logger_file
|
||||
|
|
@ -43,7 +44,7 @@ if torun.include? :manager
|
|||
Vmpooler::PoolManager.new(
|
||||
config,
|
||||
logger,
|
||||
Vmpooler.redis_connection_pool(redis_host, redis_port, redis_password, redis_connection_pool_size, redis_connection_pool_timeout, metrics),
|
||||
Vmpooler.redis_connection_pool(redis_host, redis_port, redis_password, redis_connection_pool_size, redis_connection_pool_timeout, metrics, redis_reconnect_attempts),
|
||||
metrics
|
||||
).execute!
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue