Open jmendezm opened 5 years ago
Actually, poolboy:transaction/2 is using poolboy:checkout/3 with Block = true. This means that the atom 'full' is not returned. Thus, I think this PR can be closed.
Instead, if the pool is full, the call to poolboy:transaction/2 is blocking. When it times out, it causes an exit:{timeout, {gen_server, call, _}}
exception which is converted to {error, no_connection}
by the try-catch in eredis_cluster_pool
. This causes a refresh mappings and then a retry. The refresh mappings is unnecessary in this case. We have a fix for that here: https://github.com/Nordix/eredis_cluster/pull/27.
Avoid error in function eredis_cluster_pool_worker:query() when poolboy return full instead of a Worker PID because pool is full