Skip to content

Hosting: a connection-mode resolver with reconnect and restart (upstream's ServerConnection.resolve) #850

Closed

Description

@Blind-Striker

What

A connection-mode resolver like upstream CLI's ServerConnection.resolve. It chooses between an explicit endpoint, a private server and the shared background service, applies the startup and version policy, and returns reconnect and restart operations.

Upstream at the pin (v2.3.0)

packages/cli/src/services/server-connection.ts:27, resolve. Its managed service's restart stops with a terminal handoff and then ensures (:68-77).

The SDK today

The underlying doors exist: explicit construction, StartAsync, DiscoverAsync and EnsureAsync. Every host writes the choice between them itself. A terminal-preserving restart needs #842.

Done when

Activity

  1. added this to the 1.2.0 milestone on Nov 14, 2026
  2. added
    enhancement
    on Nov 14, 2026
  3. Blind-Striker commented on Nov 14, 2026

    @Blind-Striker
    CollaboratorAuthor

    Added to this issue's scope (the maintainer, 2026-11-14): the server-version warning.

    • Upstream at the pin (v2.3.0, a6b15d33): packages/cli/src/services/server-connection.ts:40-48. For an explicit endpoint, resolve reads server.info with a 5-second deadline and, when health.version !== OPENCODE_VERSION, warns: "Server at … has version …; this client is …. Continuing anyway."
    • The SDK today: docs/architecture/client-runtime.md:875-877 says "the SDK carries no version comparand of its own". The pinned release is known at build time (spec/SNAPSHOT.md), so the comparand exists.

    Additional done-when for the resolver:

    • The resolver compares the server's reported version with the pinned release, and warns and continues the way upstream does. The PR names the .NET channel for the warning, with its reason.
    • The client-runtime.md sentence about having no comparand is corrected.
    • Tests cover a matching and a differing version.
  4. 31 remaining items

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancement

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions