chore: Update SBOM#2
Open
github-actions[bot] wants to merge 1 commit into
Open
Conversation
comandeo-mongo
added a commit
that referenced
this pull request
Apr 23, 2026
Copilot review on PR mongodb#3028 identified two correctness bugs in the initial anti-barging fix: 1. Lost wakeup (comments #1/#2): When a successful waiter leaves the size gate, it does not signal the next waiter. A newcomer that arrived during the wake-up window (observing a stale size_waiters>0) can be parked on size_cv with capacity already available, and will not be woken by any subsequent event unless an external check-in happens. Symptom: newcomer waits for the full wait_queue_timeout despite capacity being free, even under light load. Fix: after a successful checkout (once @checked_out_connections is updated), signal size_cv if there are waiters AND the gate predicate is satisfied for them. The predicate guard matters: signaling unconditionally would wake a waiter whose predicate still fails, causing it to requeue itself at the back of the FIFO and break the wait-queue-fairness CMAP spec test. The same pattern is mirrored in wait_for_connection for @max_connecting_cv. 2. Unlimited pool (comment mongodb#4): must_wait fired even when max_size==0, introducing pointless blocking for unbounded pools where there is no size constraint to wait on. Skip the gate in that case. Validation: - New white-box regression test reproduces the lost wakeup deterministically by instrumenting size_cv.wait to release the lock during the wake-up window. - spec/spec_tests/cmap_spec.rb wait-queue-fairness case (CMAP unified test): 16 examples, 0 failures. - spec/mongo/server/connection_pool_spec.rb and spec/mongo/server/connection_pool/: 115 examples, 0 failures, 3 pending. - spec/spec_tests/cmap_spec.rb (full): 226 examples, 0 failures. - profile/connection_pool_fairness.rb at 200:5 ratio: 0 timeouts, even distribution.
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.
Automated SBOM Update
This PR was automatically generated because dependency
manifest files changed.
Changes
sbom.jsonto reflect current dependenciesVerification
The SBOM was generated using @cyclonedx/cdxgen v11.0.0 with
the ruby type.
Triggered by
This PR was created automatically by the SBOM workflow