Open amanape opened 2 months ago
Related #1451
Hmm I'm not sure we need a new websocket or EventStream here. Instead, I'd like to figure out why errors aren't propagating immediately over the current WS/ES--is there some reason that they're getting blocked?
From our earlier discussion on Slack, we could change the issue to focus on pushing any and all relevant errors or build indicators to the frontend first and then see how well it handles and what changes we can make to the event stream
@rbren - the EventStreamRuntime is single-task currently, iirc, and our traffic isn't async yet.
This issue is stale because it has been open for 30 days with no activity. Remove stale label or comment or this will be closed in 7 days.
Summary Create a new event stream / channel in the form of another WebSocket connection or message queue that is dedicated for sharing non-agent related data. Things like error messages, loading indicators, and other notifications of the sort could benefit from a separate channel as it would be sent quickly and without blocking the main event stream (or the other way around)
Motivation We need to find a way to push certain message in the backend that are not being sent to the UI in an efficient manner that does not slow down the main event. For example, an error that is thrown and its details (missing API Key), loading indicators (pulling docker image), and so on
Technical Design Unlike the current event stream, this channel does not have to be bi-directional. As for the actual implementation, the options are another WebSocket path or a message queue-like setup where we can publish and subscribe to the different events
Alternatives to Consider
Additional context