Connection pool specific backports for v19#153
Connection pool specific backports for v19#153arthurschreiber wants to merge 2 commits intorelease-19.0-githubfrom
Conversation
Signed-off-by: Vicent Marti <vmg@strn.cat> Signed-off-by: Arthur Schreiber <arthurschreiber@github.com>
Signed-off-by: Harshit Gangal <harshit@planetscale.com> Signed-off-by: Vicent Martí <42793+vmg@users.noreply.github.com> Co-authored-by: Vicent Martí <42793+vmg@users.noreply.github.com>
There was a problem hiding this comment.
Pull Request Overview
This pull request backports connection pool improvements for v19 by introducing a new monotonic timestamp type and refactoring several connection pool methods and tests.
- Introduces a new, atomic-based monotonic timestamp type for connection tracking.
- Refactors connection pool methods to use monotonic time for improved expiration and renewal logic.
- Updates tests to use atomic booleans and adjust assertions per the new connection behavior.
Reviewed Changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| go/pools/smartconnpool/timestamp.go | Introduces a lightweight, atomic timestamp for monotonic time. |
| go/pools/smartconnpool/stack.go | Removes PopAll in favor of a Peek function for lock-free stack access. |
| go/pools/smartconnpool/pool_test.go | Updates tests to use atomic.Bool and adjusts connection assertions. |
| go/pools/smartconnpool/pool.go | Refactors connection pool operations to use monotonic timestamps. |
| go/pools/smartconnpool/connection.go | Changes timestamp fields from time.Time to the new timestamp type. |
|
This PR is being marked as stale because it has been open for 30 days with no activity. To rectify, you may do any of the following:
If no action is taken within 7 days, this PR will be closed. |
|
This PR was closed because it has been stale for 7 days with no activity. |
|
This PR is being marked as stale because it has been open for 30 days with no activity. To rectify, you may do any of the following:
If no action is taken within 7 days, this PR will be closed. |
|
This PR is being marked as stale because it has been open for 30 days with no activity. To rectify, you may do any of the following:
If no action is taken within 7 days, this PR will be closed. |
|
This PR was closed because it has been stale for 7 days with no activity. |
Description
This backports the changes from the following two pull requests:
Related Issue(s)
Checklist
Deployment Notes