While using NimblePool, I had the need to register my pools in a Registry.
My first attempt led me to call Registry.register/3 in the NimblePool.init/1 callback, but this is actually for the workers and not the pool itself.
This pr adds an optional init_pool/1 callback to the NimblePool behaviour where one is now able to perform a registration if needed, or customize the pool state itself.
While using NimblePool, I had the need to register my pools in a Registry.
My first attempt led me to call
Registry.register/3
in theNimblePool.init/1
callback, but this is actually for the workers and not the pool itself.This pr adds an optional
init_pool/1
callback to theNimblePool
behaviour where one is now able to perform a registration if needed, or customize the pool state itself.