Skip to content

fix: drain proxy requests before closing DRPC - #29724

Merged
pawbana merged 3 commits into
mainfrom
pawel/aigov-615-reverse-proxy-handler-with-recorder-lifecycle-and-key-7
Oct 1, 2026
Merged

pawbana merged 3 commits into
mainfrom
pawel/aigov-615-reverse-proxy-handler-with-recorder-lifecycle-and-key-7

Conversation

@pawbana

@pawbana pawbana commented Sep 22, 2026 •

Copy link
Copy Markdown
Collaborator

Keep DRPC available while admitted AI Gateway proxy requests drain, rather than canceling the DRPC connection lifecycle at the start of shutdown.
After shutdown reject new handler acquisition immediately.
Once requests finish or the shutdown context expires, cancel remaining proxy requests and the DRPC lifecycle. Shutdown stops waiting for the DRPC connection loop when its deadline expires.
Reconnects skip initialization once a backend is selected.

Generated by Coder Agents on behalf of @pawbana.

@linear-code

linear-code Bot commented Sep 22, 2026

Copy link
Copy Markdown

AIGOV-615

@pawbana pawbana removed their assignment Sep 22, 2026
@pawbana
pawbana added this pull request to stack #29736 September 22, 2026 16:14
@pawbana
pawbana force-pushed the pawel/aigov-615-reverse-proxy-handler-with-recorder-lifecycle-and-key-6 branch from 0d59fb8 to 1908428 Compare September 24, 2026 17:31
@pawbana
pawbana removed this pull request from stack #29736 September 24, 2026 17:36
@pawbana
pawbana force-pushed the pawel/aigov-615-reverse-proxy-handler-with-recorder-lifecycle-and-key-6 branch 2 times, most recently from 2f060a1 to 4e5b5d9 Compare September 24, 2026 20:13
@pawbana
pawbana force-pushed the pawel/aigov-615-reverse-proxy-handler-with-recorder-lifecycle-and-key-7 branch 2 times, most recently from 6c57675 to 97ede3e Compare September 24, 2026 21:26
@pawbana pawbana changed the title fix: drain admitted AI Gateway requests before shutdown fix(coderd/aibridged): drain proxy requests before closing DRPC Sep 24, 2026
@pawbana
pawbana force-pushed the pawel/aigov-615-reverse-proxy-handler-with-recorder-lifecycle-and-key-7 branch 6 times, most recently from fc79f6a to 26c67a8 Compare September 28, 2026 11:14
@pawbana
pawbana force-pushed the pawel/aigov-615-reverse-proxy-handler-with-recorder-lifecycle-and-key-6 branch 2 times, most recently from 28bdcad to 9bc299b Compare September 28, 2026 21:04
Base automatically changed from pawel/aigov-615-reverse-proxy-handler-with-recorder-lifecycle-and-key-6 to main September 28, 2026 21:24
@pawbana
pawbana force-pushed the pawel/aigov-615-reverse-proxy-handler-with-recorder-lifecycle-and-key-7 branch 2 times, most recently from affe217 to f070c19 Compare September 29, 2026 12:38
@pawbana
pawbana marked this pull request as ready for review September 29, 2026 12:49
@pawbana
pawbana force-pushed the pawel/aigov-615-reverse-proxy-handler-with-recorder-lifecycle-and-key-7 branch from f070c19 to 116c8ff Compare September 29, 2026 12:50
@pawbana pawbana changed the title fix(coderd/aibridged): drain proxy requests before closing DRPC fix: drain proxy requests before closing DRPC Sep 29, 2026
@pawbana
pawbana force-pushed the pawel/aigov-615-reverse-proxy-handler-with-recorder-lifecycle-and-key-7 branch 2 times, most recently from 98ccbfd to 7dc2cf5 Compare September 30, 2026 09:18
Comment thread cli/server_test.go Resolved
@pawbana
pawbana force-pushed the pawel/aigov-615-reverse-proxy-handler-with-recorder-lifecycle-and-key-7 branch from a342786 to 9f6762e Compare October 1, 2026 12:00
@pawbana
pawbana force-pushed the pawel/aigov-615-reverse-proxy-handler-with-recorder-lifecycle-and-key-7 branch from 9f6762e to 386352e Compare October 1, 2026 12:13
@pawbana
pawbana enabled auto-merge (squash) October 1, 2026 12:16
@pawbana
pawbana merged commit 7e64b46 into main Oct 1, 2026
28 of 29 checks passed
@pawbana
pawbana deleted the pawel/aigov-615-reverse-proxy-handler-with-recorder-lifecycle-and-key-7 branch October 1, 2026 12:25
@github-actions github-actions Bot locked and limited conversation to collaborators Oct 1, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants