Skip to content

Add optional promise parameter to RedisConnectionPool.close

tanner requested to merge tn-pool-close-promise into master

Adds an optional EventLoopPromise<Void> parameter to RedisConnectionPool.close.

let pool = RedisConnectionPool(...)

let promise = pool.eventLoop.makePromise(of: Void.self)
pool.close(promise: promise)
try promise.futureResult.wait()

Previously, the close method offered no way to be notified or wait for the close to complete.

Edited by tanner

Merge request reports