feat(seasonpass): bump mainnet image to git-887fe57 (deploy #308 GQL-out-of-txn + #306 pool 60)#3496
Merged
Merged
Conversation
…out-of-txn + #306 pool 60) #308 is stacked on #306, so this single tag bump ships both on top of the currently-live ba5228c: 485b172 raise DB pool 30 -> 60 [#306] 887fe57 call cleared-stage RPC outside the DB transaction [#308] The #308 refactor moves the slow get_last_cleared_stage GQL call out of the DB transaction in the status paths, so a request no longer holds a user_season_pass row lock idle-in-transaction across that RPC. That hold was piling up claim "SELECT ... FOR UPDATE" waiters and exhausting the SQLAlchemy pool, timing out every DB endpoint and tripping the block-status / invalid-claim monitors together. code-reviewer verdict: merge — intended behavior verified (no DetachedInstanceError on the happy path; rollback releases the connection/lock before the RPC). Known follow-ups (non-blocking): narrow guard for the rollback->commit concurrent-delete window, and status-endpoint integration tests. No migration coupling: the #307 partial index is already applied live and the code works with or without it. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.
What
Bumps the mainnet
seasonpass.image.tagfromgit-ba5228ctogit-887fe57.#308 (
fix/gql-outside-db-txn) is stacked on #306, so this single tag bump ships both on top of the currently-liveba5228c:485b172887fe57(Live
ba5228calready hadcc9e3f8async/ping+ba5228canyio threadpool cap.)Why
Repeated block-status / invalid-claim alarms (Assertible → PagerDuty / #9c-mainnet-alert). Root cause caught live via
pg_stat_activity: a status request held auser_season_passrow lock idle-in-transaction for 150s+ while doing a slowget_last_cleared_stageGQL call. That piled up claimSELECT ... FOR UPDATEwaiters (up to ~1300s), drove the SQLAlchemy pool to 30/30, and timed out every DB endpoint → both monitors tripped together.#308 moves the GQL call out of the transaction in the three status paths (
get_default_uspWORLD_CLEAR,user_status/all_user_statusexp==0 refetch): capture the needed scalars,rollback()to release the connection/lock, then do the RPC. #306's pool 60 is the headroom backstop.Review
code-reviewerverdict: merge — no blocking issues on the production money-path.DetachedInstanceErroron happy path (FastAPI serializes before session teardown; expired-but-attached objects lazy-reload).season_pass=→season_pass_id=safe. No write loss. outer try/except handles RPC timeout without connection leak.rollback()→commit()concurrent-delete window can 500 onObjectDeletedError(low probability — these rows are rarely deleted); (2)expire_on_commitlazy-reload adds extra checkouts at serialization (net-positive vs the long holds).pass_typeshadowing; status-endpoint test gap.Migrations
None coupled. The #307 partial index (
idx_claim_unsettled) is already applied live, and this code works with or without it. Migrations are applied manually (no init-container/Job).Deploy
ArgoCD
9c-external-serviceshas no auto-sync — after merge, manual sync required:🤖 Generated with Claude Code