Durable remote session identity for an agent workspace.
Workspaces own remote identity. Tabs may project this data for display, but lifecycle code should read the workspace copy so reconnect and teardown still work when a file tab is active or the agent tab has been closed.
Summary
Functions
Returns true when the remote metadata points at the server/session pair.
Creates durable remote metadata.
Returns true when the remote metadata belongs to the server.
Updates the connection status.
Updates the last seen event id.
Types
@type connection_status() :: :connected | :disconnected | :ended | :unavailable
Remote connection status.
@type t() :: %MingaEditor.State.Workspace.RemoteSession{ connection_status: connection_status(), last_seen_event_id: non_neg_integer(), server_name: String.t(), session_id: String.t() }
Durable remote session metadata for a workspace.
Functions
Returns true when the remote metadata points at the server/session pair.
@spec new(String.t(), String.t(), connection_status(), non_neg_integer()) :: t()
Creates durable remote metadata.
Returns true when the remote metadata belongs to the server.
@spec set_connection_status(t(), connection_status()) :: t()
Updates the connection status.
@spec set_last_seen_event_id(t(), non_neg_integer()) :: t()
Updates the last seen event id.