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

connection pool same-context enforced option #1317

Open
franz1981 opened this issue Apr 22, 2023 · 2 comments
Open

connection pool same-context enforced option #1317

franz1981 opened this issue Apr 22, 2023 · 2 comments

Comments

@franz1981
Copy link

It would be great an option to enforce acquisition of connections just from the same context, for maximum performance or been parked if not found any; together with some telemetry to measure both latencies to acquire leases and miss/hit/release/wait/resume counters to measure effectiveness. This would help both as a proper option and to check what's the advantage of stealing connections that belong to another context.

@franz1981
Copy link
Author

franz1981 commented Apr 22, 2023

I am just sad that if we just want to pick connection from the same context probably we don't need a combiner executor but we could just use per-context (and single threaded) stacks/queues and same for waiters; and a global max connections counter (using compareAndSet to modify the shared count)

The combiner instead can be used to trigger periodic randevouz to rebalance connections count/shares.
@vietj

@vietj
Copy link
Member

vietj commented Apr 24, 2023 via email

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

No branches or pull requests

2 participants