Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow to use channel manager provided via config #1557

Closed

Conversation

beargummy
Copy link

Sometimes it could be useful to provide custom ChannelManager and/or reuse it, like it is done with Timer.
Also, to support this feature, method releaseChannelLock is being reused in DefaultChannelGroup#remove, since logic is effectively the same.

Daniil Kudryavtsev added 2 commits July 6, 2018 19:47
Add ChannelManager to AHC config to be able to reuse ChannelManager and to provide custom implementation.
@slandelle
Copy link
Contributor

Sorry, but that's not possible. ChannelManager is an internal, not a public API, so it can can any time. Please explain your actual use case.

@slandelle slandelle closed this Jul 9, 2018
@beargummy
Copy link
Author

@slandelle actual use case is to be able to use custom channel(connections) limitations, not only global and per-host. This is partially achievable via custom ChannelPoolPartitioning with necessary logic, but it lacks custom limits. E.g. I want to limit per-host connections to some huge number of connections and also add different (lower) custom limit based on some request parameters.

@slandelle
Copy link
Contributor

Looks like you need something related to ConnectionSemaphore. Feel free to suggest API changes for your use case.

@beargummy
Copy link
Author

I'd like to, and I definitely will, but ConnectionSemaphore is part of 2.4.x version, and unfortunately I cannot migrate to this version due to open netty's issue. That's why I want to provide custom ChannelManager.

@slandelle
Copy link
Contributor

IIRC, issue #6706 has actually always been there and is not related to a Netty upgrade.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants