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

feat: Client pool interns keys #204

Merged
merged 2 commits into from
Oct 24, 2024
Merged

Conversation

alexrudy
Copy link
Owner

By replacing most direct uses of connection keys with an opaque token, many client types no longer require the generic argument for the key type, greatly simplifying the implementation.

Connection pool keys are converted to opaque, copyable tokens when checkouts are created from the pool, with keys that hash equivalently returning the same token. Then the pool uses these tokens in place of the keys in internal data structures.

By replacing most direct uses of connection keys with an opaque token, many client types no longer require the generic argument for the key type, greatly simplifying the implementation.

Connection pool keys are converted to opaque, copyable tokens when checkouts are created from the pool, with keys that hash equivalently returning the same token. Then the pool uses these tokens in place of the keys in internal data structures.
@alexrudy alexrudy merged commit 80d15cb into main Oct 24, 2024
16 checks passed
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.

1 participant