feat(cockpit): add browser session client - #3205
Conversation
Greptile SummaryAdds a browser-side cockpit session client.
Confidence Score: 3/5The reconnect state-retention defect should be fixed before merging because replacement sessions can display telemetry left by a dead producer. A new transport run reuses the Session's non-null manifest and ChannelStore, so receiving an identical manifest bypasses reset and leaves old channel slots visible under the newly confirmed producer. Files Needing Attention: web/cockpit/src/session/session.ts Important Files Changed
Sequence DiagramsequenceDiagram
participant UI as Cockpit UI
participant Session
participant Transport as ReconnectingTransport
participant Relay
UI->>Session: startSession()
Session->>Transport: start()
Transport->>Relay: fetch /api/info and connect
Session->>Relay: hello
Relay-->>Session: welcome and robots
Session->>Relay: watch robot
Relay-->>Session: manifest
Session->>Relay: subscribe to decodable channels
Relay-->>Session: data frames
Session-->>UI: publish channel snapshots
Relay--xTransport: connection closes
Transport->>Relay: reconnect
Note over Session: Existing manifest and slots remain
Relay-->>Session: identical replacement manifest
Note over Session,UI: Equal-manifest branch preserves stale slots
Reviews (1): Last reviewed commit: "feat(cockpit): add browser session clien..." | Re-trigger Greptile |
Codecov Report✅ All modified and coverable lines are covered by tests. @@ Coverage Diff @@
## main #3205 +/- ##
==========================================
- Coverage 75.02% 75.01% -0.01%
==========================================
Files 1120 1120
Lines 107091 107091
Branches 9719 9719
==========================================
- Hits 80340 80339 -1
- Misses 23941 23944 +3
+ Partials 2810 2808 -2
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
504a03a to
4e0ca2a
Compare
6d646b0 to
4c2b03d
Compare
4c2b03d to
13c72b9
Compare
Uh oh!
There was an error while loading. Please reload this page.