Repository navigation
fix: gateway request blocked in store jobs blocking all other requests - #6760
Merged
Merged
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #6760 +/- ##
==========================================
- Coverage 80.05% 79.76% -0.30%
==========================================
Files 565 565
Lines 63267 63301 +34
==========================================
- Hits 50651 50494 -157
- Misses 9631 9829 +198
+ Partials 2985 2978 -7 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
atzoum
marked this pull request as ready for review
March 12, 2026 19:03
atzoum
marked this pull request as draft
March 12, 2026 19:03
🔒 Scanned for secrets using gitleaks 8.30.0
🔒 Scanned for secrets using gitleaks 8.30.0
atzoum
marked this pull request as ready for review
March 13, 2026 10:51
ktgowtham
approved these changes
Mar 13, 2026
This was referenced Mar 16, 2026
Merged
itsmihir
pushed a commit
that referenced
this pull request
Mar 16, 2026
🤖 I have created a release *beep* *boop* --- ## [1.70.0-rc.1](v1.69.0...v1.70.0-rc.1) (2026-03-16) ### Features * add a scheduled release cut workflow to cut release branches ([#6739](#6739)) ([ab887ac](ab887ac)) * infer OAuth type from account definition when destination supports accounts ([#6718](#6718)) ([00d1755](00d1755)) ### Bug Fixes * false sanity check failure due to empty response ([#6762](#6762)) ([0384603](0384603)) * gateway request blocked in store jobs blocking all other requests ([#6760](#6760)) ([ca4d514](ca4d514)) * respect context cancellation in gateway rate limiter ([#6751](#6751)) ([589251a](589251a)) * update prerelease branch versioning format in scheduled release workflow ([#6745](#6745)) ([fede9e4](fede9e4)) ### Miscellaneous * add check for pseudo-version dependencies in rudderlabs modules ([#6737](#6737)) ([55ecd10](55ecd10)) * bump rudder-go-kit to 0.73.0 ([#6753](#6753)) ([1743f6b](1743f6b)) * remove gunicorn and add darwin compatibility ([#6742](#6742)) ([392d1f4](392d1f4)) * use latest retryablehttp client ([#6754](#6754)) ([629f036](629f036)) * user rudo docker image for partition migration integration tests ([#6757](#6757)) ([5022fbd](5022fbd)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). Co-authored-by: rudderstack-github-actions[bot] <236995729+rudderstack-github-actions[bot]@users.noreply.github.com>
itsmihir
pushed a commit
that referenced
this pull request
Mar 17, 2026
🤖 I have created a release *beep* *boop* --- ## [1.70.0](v1.69.0...v1.70.0) (2026-03-16) ### Features * add a scheduled release cut workflow to cut release branches ([#6739](#6739)) ([ab887ac](ab887ac)) * infer OAuth type from account definition when destination supports accounts ([#6718](#6718)) ([00d1755](00d1755)) ### Bug Fixes * false sanity check failure due to empty response ([#6762](#6762)) ([0384603](0384603)) * gateway request blocked in store jobs blocking all other requests ([#6760](#6760)) ([ca4d514](ca4d514)) * respect context cancellation in gateway rate limiter ([#6751](#6751)) ([589251a](589251a)) * update prerelease branch versioning format in scheduled release workflow ([#6745](#6745)) ([fede9e4](fede9e4)) ### Miscellaneous * add check for pseudo-version dependencies in rudderlabs modules ([#6737](#6737)) ([55ecd10](55ecd10)) * bump rudder-go-kit to 0.73.0 ([#6753](#6753)) ([1743f6b](1743f6b)) * remove gunicorn and add darwin compatibility ([#6742](#6742)) ([392d1f4](392d1f4)) * use latest retryablehttp client ([#6754](#6754)) ([629f036](629f036)) * user rudo docker image for partition migration integration tests ([#6757](#6757)) ([5022fbd](5022fbd)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). Co-authored-by: rudderstack-github-actions[bot] <236995729+rudderstack-github-actions[bot]@users.noreply.github.com>
1 task done
atzoum
added a commit
that referenced
this pull request
Nov 6, 2026
#7578) # Description Cancelling a transaction's context while a COPY is open makes `database/sql` send `ROLLBACK` while lib/pq's COPY response reader is still reading the connection. One of the two then waits forever for a reply the other consumed, holding the connection lock, so the store never returns; in the partition migration server this also blocks gRPC shutdown. This is probably also what caused the gateway hangs behind #6760: `storeJobs` cancels its transaction at `WriteTimeout`, and the stacks in that PR show the same deadlock, with `Tx.awaitDone` stuck in `Rollback` and `doStoreJobsInTx` waiting on `Stmt.Close`. The `startStoreJobsWatchdog` added there stays in place. Points `lib/pq` at `rudderlabs/pq`, v1.12.3 plus a fix that ends the COPY before `ROLLBACK`/`COMMIT`. The `replace` goes away once lib/pq#1452 is fixed in a release. ## Linear Ticket n/a ## Security - [x] The code changed/added as part of this pull request won't create any security issues with how the software is being used.
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.
🔒 Scanned for secrets using gitleaks 8.30.0
Description
Due to an intermittent network issue, we noticed that although postgres cancelled the
COPYcommand, the client never received the response. This caused the store method to remain blocked indefinitely, which in turn blocked all other requests because of thedsListLockmutex.To prevent the gateway from being blocked indefinitely, we are adding a watchdog that triggers a panic if the write operation exceeds the 1 minute grace period post the write timeout.
Security