internal/carrier and internal/carrier/builtin sat between transports and
engines, wrapping every engine.Session in carrier.Session +
engineByteStream/engineVideoTrack adapters that mechanically proxied every
method. That layer existed solely to translate Capabilities/AddTrack names;
no behaviour lived above engine.
Replace with internal/engine/builtin: a name-keyed registry that calls
auth.Issue and engine.New directly. Transports look up engine.Session via
enginebuiltin.Open, then type-assert engine.VideoTrackCapable for video
transports. A small per-transport engineVideoSession adapter unifies the
reconnect callback signature (engine uses func(*webrtc.DataChannel); the
transports want func()).
Updates:
- internal/engine/builtin/builtin.go: new Register/Open registry + auth
pass-through ("none") + auth-driven factories for jazz/telemost/wbstream/jitsi.
- internal/transport/datachannel/transport.go: uses engine.Session directly
via Capabilities().ByteStream check.
- internal/transport/{seichannel,videochannel,vp8channel}: each gains an
engineVideoSession adapter and routes Connect/Send/Close/AddTrack through
the engine session.
- internal/app/session: imports enginebuiltin; carrier.Available() →
enginebuiltin.Available().
- pkg/olcrtc/olcrtc.go: switches to enginebuiltin.RegisterDefaults.
- internal/carrier and internal/carrier/builtin: deleted.
- Tests rewritten to register a fakeEngineSession (implements engine.Session
+ engine.VideoTrackCapable) through enginebuiltin.Register. The e2e
memoryStream gains the same dual interface so memorySession is gone.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Decompose the monolithic internal/provider/telemost package into two
orthogonal layers: engine/goolom (Yandex proprietary SFU wire protocol —
WebSocket signaling, dual pub/sub PeerConnections, DataChannel, telemetry)
and auth/telemost (HTTP connection-info fetch → engine.Credentials).
Add engine.Config.Refresh callback so Goolom can obtain fresh peerID and
credentials on every reconnect without a direct dependency on the auth
package. engine_adapter wires the Refresh closure from authProvider.Issue.
Delete internal/provider/ entirely (telemost was the last tenant) and
remove the now-obsolete provider_adapter + its test from builtin.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Split the SaluteJazz provider along the same engine/auth seam used for
WB Stream:
- internal/engine/salutejazz — Sber WS+SDP signaling engine (pub/sub
split, _reliable data channel, length-prefixed DataPacket envelope).
Consumes URL/Token/Extra[password] from engine.Config; no embedded
HTTP/auth logic. Registered as engine "salutejazz".
- internal/auth/salutejazz — create-meeting + preconnect flow.
Implements auth.Provider (Engine() → "salutejazz") and
auth.RoomCreator. Accepts cfg.RoomURL in "<roomID>:<password>" form
for join, or empty / "any" / "dummy" for create-on-the-fly, matching
the legacy provider.
The carrier name "jazz" now goes through registerEngineAuth.
engine.Config gains an Extra map so auth providers can pass engine-
specific fields (password here); engine_adapter forwards
auth.Credentials.Extra into it.
session.Gen for jazz uses the auth.RoomCreator capability. Output now
includes the password ("<roomID>:<password>") — without it the printed
room is not joinable, so the legacy roomID-only output was effectively
broken for the gen flow.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Split the WB Stream provider into two orthogonal pieces:
- internal/engine/livekit — generic LiveKit transport (URL+Token only,
no service-specific assumptions). Registered as engine "livekit".
- internal/auth/wbstream — WB Stream API flow (guest register, join,
token exchange). Implements auth.Provider and auth.RoomCreator,
reports engine "livekit".
The carrier name "wbstream" now goes through registerEngineAuth, which
wires the auth provider to the engine it declares. CLI surface is
unchanged. session.Gen for wbstream calls the RoomCreator directly;
that path will become fully generic in a later step. jazz and telemost
remain on the legacy provider path for now.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Lay the groundwork for splitting service-specific logic (WB / Jazz /
Telemost API flows) from wire-level transport engines (LiveKit, Goolom,
future Jitsi). An engine takes only URL+Token+Name+network knobs; an
auth provider produces those credentials and reports which engine it
feeds. RoomCreator is an optional capability for the gen mode.
Existing carriers and providers are untouched.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>