Serverless listener forwards /start to the application when basePath is "/"
メンテナーはふだん 1 日以内に返信
@Saisharathchandranandnetha がすでに取り組んでいます。
2026年9月19日 から。
- #5756 @Saisharathchandranandnetha による — オープン
評価
調査の方向性
rivetkit-rust/packages/rivetkit-core/src/serverless.rs の handles_listener_request から始め、次に route_path と関連する serverless テストを確認してください。root のベースパスの再現を使って、指定された cargo test を実行します。完了条件は、/, /start, /health, /metadata, /metrics が予約され、/application がアプリケーションに転送されることです。
索引モデルが issue の本文から書いたものです。
説明
What happens
With serverless.basePath: "/" and an application passed to registry.listen(), the Rust listener forwards the engine's POST /start to the application instead of handling it. Same for /health, /metadata and /metrics. Actors on that pool never start. The same config works through registry.handler().
Where
handles_listener_request in rivetkit-rust/packages/rivetkit-core/src/serverless.rs:
let request_path = parsed.path();
if request_path != base_path && !request_path.starts_with(&format!("{base_path}/")) {
return false;
}
Why it happens
normalize_base_path(Some("/")) returns "/", so the prefix check looks for "//". No request path starts with //, so everything except / itself returns false. serverless_http.rs only hands a request to the runtime when this returns true or when there's no application, so /start ends up in the user's handler.
route_path already handles a root base path correctly. It's only this check. The TypeScript side special-cases it in isServerlessStartRequest (basePath === "/" ? "" : ...), which is why registry.handler() works.
Reproduction
Add to rivetkit-rust/packages/rivetkit-core/tests/serverless.rs:
#[test]
fn listener_reserves_framework_routes_for_root_base_path() {
let base_path = normalize_base_path(Some("/"));
for path in ["/", "/start", "/health", "/metadata", "/metrics"] {
assert!(
handles_listener_request(&base_path, &format!("http://internal{path}")),
"root base path should reserve {path}"
);
}
assert!(!handles_listener_request(&base_path, "http://internal/application"));
}
cargo test -p rivetkit-core --lib listener_reserves_framework_routes_for_root_base_path fails with root base path should reserve /start.
Expected behaviour
With a root base path the listener handles /, /start, /health, /metadata and /metrics itself and forwards everything else to the application.
Suggested fix
Treat base_path == "/" as matching every request path before the prefix check. route_path already returns the right route in that case. Happy to open a PR.
Environment
- upstream/main at
78336a1a0 - Linux 7.2.5-3-omarchy
- rustc 1.98.1 (48a229cea 2026-09-01), cargo 1.98.1 (797e8a9bc 2026-08-05)
- 主要言語
- Rust
- スター
- 6.3k
- フォーク
- 280
- 平均マージ
- 21時間 17分
- マージ済み PR(30日)
- 34
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドなし
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
rivet-dev/rivet のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
rivet-dev/rivet#5891 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
Rust client drops connection-level errors when actionId is null (JSON/CBOR)対応中かも @DibbayajyotiRoy が 22 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
rivet-dev/rivet#5819 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
Queue docs say completable messages are removed on receive, but they stay stored until complete()対応中かも @Saisharathchandranandnetha が 33 日前に担当しました。 オープン
難易度 1/5 1〜3時間 初心者へのやさしさ 91/100
rivet-dev/rivet#5762 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
rivet-dev/rivet#5915 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
rivet-dev/rivet#5908 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
rivet-dev/rivet の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 85/100
farion1231/cc-switch#8829 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
Validate CI command vectors before indexing Cargo subcommands対応中かも @amandeavor が今日担当しました。 オープンbug ci good first issue
難易度 2/5 1〜3時間 初心者へのやさしさ 88/100
メンテナーはふだん 1 日以内に返信
-
難易度 1/5 1時間未満 初心者へのやさしさ 92/100
longbridge/gpui-kit#3677 ·
メンテナーはふだん 1 日以内に返信
-
E-pr-welcome
難易度 2/5 1〜3時間 初心者へのやさしさ 77/100
seanmonstar/reqwest#3121 · コメント 2 件 ·
メンテナーはふだん 1 日以内に返信
-
難易度 1/5 1時間未満 初心者へのやさしさ 68/100
ilya-zlobintsev/LACT#1235 ·
メンテナーはふだん 1 日以内に返信