Allow configuration of Netty NIO boss executor#7
Closed
trask wants to merge 1 commit into
Closed
Conversation
Contributor
|
Hi, I added support for what you wanted using the NettyAsyncHttpProviderConfig element. All you need to do is to described here Thanks! -- Jeanfrancois |
Contributor
Author
|
Great, thank you. |
|
trask, was this so that you could get netty to use threads from your own thread pool? like an Akka dispatcher? |
Contributor
|
@astubbs That was for allowing configure two threads pools (hence you can use Akka stuff for both): The Netty's boss executor (used by Netty internally) and the applicationThreadPool (which is configurable using the AsyncHttpClientConfig). |
|
Cool. Problem is, I can't see how to get a java.util.concurrent.ExecutorService out of an Akka dispatcher.. |
cs-workco
pushed a commit
to cs-workco/async-http-client
that referenced
this pull request
Apr 13, 2023
motivation: min requirements by sswg changes: * add code of conduct, contributors * add docker setup for ci * add linux docs generation and sanity check scripts * add api documentation generation script
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hi, I couldn't find a way to supply my own ExecutorService instance for this particular thread pool without modifying your library (I wish to use a custom ThreadFactory for it). Initially I thought of adding this as a configuration parameter in AsyncHttpClientConfig, but then realized AsyncHttpClientConfig is not Netty specific and so I decided maybe it wasn't appropriate there and just added an extra constructor in NettyAsyncHttpProvider to handle this. Please let me know if I missed something or if there is another solution you would prefer that I implement. Thanks.