o2r channel merge: CLI verb for first-class channel merge #61

Closed
opened 2026-06-05 05:13:50 +00:00 by coilysiren · 1 comment
Owner

o2r channel merge - CLI verb for first-class channel merge

Channel management is exclusively the o2r CLI's surface (this repo subsumes the
agent-channel protocol). This issue tracks the operator-facing merge verb. The
relay route + semantics are in #60; land that first, the verb depends on it.

Shape

o2r channel merge <target> <source> [<source>...] [--keep-open]
  • <target> - the survivor channel id (the open one).
  • <source>... - one or more channels to fold in (closed is the normal case).
  • Default closes sources (tombstone + merged_into); --keep-open overrides.

Calls POST /agent-channel/{target}/merge with {sources, close_sources}.

Behavior

  • Print a confirmation of what moved: per-source moved event counts, the merge
    event id in the target, and the survivor URL.
  • Surface the state/spec collision warning the relay returns - if a folded
    source's newest state is newer than the survivor's it now wins. Tell the
    operator to re-seed state if needed. Do not bury it.
  • Idempotent: re-running on an already-merged source is a no-op the CLI reports
    cleanly rather than erroring.

Note

This lands as part of building out o2r channel <verb> as the first-class,
top-level, exclusive channel-management surface. If the unified o2r CLI entry
point does not exist yet, this verb motivates scaffolding it (the current
o2r-relay / o2r-view console scripts are per-layer, not a unified channel CLI).

Relay side: #60.

## `o2r channel merge` - CLI verb for first-class channel merge Channel management is exclusively the o2r CLI's surface (this repo subsumes the agent-channel protocol). This issue tracks the operator-facing `merge` verb. The relay route + semantics are in #60; land that first, the verb depends on it. ### Shape ``` o2r channel merge <target> <source> [<source>...] [--keep-open] ``` - `<target>` - the survivor channel id (the open one). - `<source>...` - one or more channels to fold in (closed is the normal case). - Default closes sources (tombstone + `merged_into`); `--keep-open` overrides. Calls `POST /agent-channel/{target}/merge` with `{sources, close_sources}`. ### Behavior - Print a confirmation of what moved: per-source moved event counts, the `merge` event id in the target, and the survivor URL. - **Surface the state/spec collision warning** the relay returns - if a folded source's newest `state` is newer than the survivor's it now wins. Tell the operator to re-seed `state` if needed. Do not bury it. - Idempotent: re-running on an already-merged source is a no-op the CLI reports cleanly rather than erroring. ### Note This lands as part of building out `o2r channel <verb>` as the first-class, top-level, exclusive channel-management surface. If the unified `o2r` CLI entry point does not exist yet, this verb motivates scaffolding it (the current `o2r-relay` / `o2r-view` console scripts are per-layer, not a unified channel CLI). Relay side: #60.
Author
Owner

Misfiled - the o2r CLI is the standalone repo coilyco-flight-deck/otel-a2a-relay-cli, not this one. The merge verb is now tracked there as otel-a2a-relay-cli#15, sibling to its list / handoff / request / verify verbs. Relay route stays here as #60.

Misfiled - the o2r CLI is the standalone repo coilyco-flight-deck/otel-a2a-relay-cli, not this one. The merge verb is now tracked there as otel-a2a-relay-cli#15, sibling to its list / handoff / request / verify verbs. Relay route stays here as #60.
Commenting is not possible because the repository is archived.
No description provided.