async-http-client
async-http-client copied to clipboard
should config.getThreadFactory take a pool name or suffix?
Both DefaultAsyncHttpClient
and ChannelManager
call config.getThreadFactory
, but when the result is null, DefaultAsyncHttpClient
instantiates a DefaultThreadFactory
with the pool name config.getThreadPoolName() + "-timer"
while ChannelManager
instantiates that same factory with the pool name config.getThreadPoolName()
.
This means that when you don't set a thread factory in the client config, you'll end up with two different pool names, but if you do set a thread factory in the client config, you'll end up with the same pool name for both use cases.
Should getThreadFactory
take a pool name (or even just a suffix) to allow differentiating its use cases in DefaultAsyncHttpClient
and ChannelManager
?
There's value in naming the (single) timer thread differently so it can be told appart from the IO threads. AFAIK, the only way to achieve the same thing would be to have 2 different ThreadFactories. Contributions welcome.
Hi @slandelle, is it still actual? I would like to take it.
Hi @mchernyakov Yes, feature request is still open, please feel free to contribute.