fix(v03): route prestop drain through v1 dispatcher (#2004)

This commit is contained in:
Lyon
2026-06-24 01:59:19 +08:00
committed by GitHub
parent ebb9580c57
commit e2813e8a27
2 changed files with 3 additions and 3 deletions
+2 -2
View File
@@ -661,7 +661,7 @@ async function handleRestAdapter(request, response, url, options) {
return;
}
if (url.pathname === "/internal/workbench/drain") {
if (url.pathname === "/v1/internal/workbench/drain") {
if (request.method !== "POST") {
sendJson(response, 405, { ok: false, error: { code: "method_not_allowed", message: "POST required." } });
return;
@@ -676,7 +676,7 @@ async function handleRestAdapter(request, response, url, options) {
timeoutMs: parsePositiveInteger((options.env ?? process.env).HWLAB_WORKBENCH_SSE_DRAIN_TIMEOUT_MS, 2500),
env: options.env ?? process.env
});
sendJson(response, 200, { ok: true, route: "/internal/workbench/drain", result });
sendJson(response, 200, { ok: true, route: "/v1/internal/workbench/drain", result });
return;
}