儀表板

修復就是一個 pull request。 Polylane 寫,你合併。

加入候補名單
github.com/coreplane/payments-api/pull/491

Cap retries on the checkout webhook worker #491

polylane
Open polylane wants to merge 1 commit into main from polylane/autofix/chat/k3x9f2-4e7d21a
Conversation 1 Commits 1 Checks 1 Files changed 2
polylane bot commented 6 minutes ago ···

Retries on the checkout webhook worker were unbounded: a failing delivery re-queued itself forever and amplified load on payments-api. This caps delivery at 5 attempts with exponential backoff and dead-letters the payload after the last one.

What changed

worker/deliver.ts gains MAX_DELIVERY_ATTEMPTS = 5 and backoff between attempts; exhausted payloads land in checkout-webhooks-dlq instead of re-queueing.

Validation

npm test — 214 passed. A forced failing delivery stopped after 5 attempts and appeared in the dead-letter queue.

Root cause · Why it's safe · Out of scope
polylane added commit 4e7d21a Verified
Review required At least 1 approving review is required
ci / test Successful in 3m 12s Details
Review required Waiting on your review: Polylane never merges on its own
Merging is blocked

一個你不必自己寫的修復。 以及信任它的理由。

  • 寫得像隊友

    在沙箱裡、在分支上,遵循你的提交慣例和儲存庫的指示。

  • 開出之前先檢查

    一次安全審查會找出正確的差異仍可能弄壞部署的方式:鎖表的遷移、版本混用造成的中斷。

  • 停在你的審查

    合併由你的審查與你的 CI 決定,就是這樣。

  • 它從一個「不」學習

    把 pull request 關閉而不合併,Polylane 會弄清楚原因,並且不再重蹈覆轍。

你的審查就是合併按鈕。 Polylane 絕不自行合併。