Follow-up from #1248.
After #1248, serve_server stays in its bootstrap loop until a request selects a lifecycle. Malformed or unsupported requests get an error response and the loop continues. Discover probes also keep the loop open. This lets clients recover, for example after a bare tools/list without _meta. But a client can also keep the connection in the pre-lifecycle state forever by sending requests that never select a lifecycle.
Open question: should rmcp cap the number of pre-lifecycle attempts (or apply a timeout)? Or should the transport that owns the connection handle this?
Options:
- Count rejected/bootstrap-neutral requests and return
ServerInitializeError after N attempts.
- Add a configurable bootstrap timeout.
- Leave this to transports and document that expectation.
Follow-up from #1248.
After #1248,
serve_serverstays in its bootstrap loop until a request selects a lifecycle. Malformed or unsupported requests get an error response and the loop continues. Discover probes also keep the loop open. This lets clients recover, for example after a baretools/listwithout_meta. But a client can also keep the connection in the pre-lifecycle state forever by sending requests that never select a lifecycle.Open question: should rmcp cap the number of pre-lifecycle attempts (or apply a timeout)? Or should the transport that owns the connection handle this?
Options:
ServerInitializeErrorafter N attempts.