mirror of
https://github.com/open-gitagent/langship.sh.git
synced 2026-08-03 07:21:04 +02:00
feat: add Gateway page and Runs page with real-time updates
- Implemented a new Gateway page that provides a uniform ingress for deployed agents. - Created a Runs page that lists recent pipeline executions with auto-refresh and error handling. - Added a RunsListener component to handle real-time notifications for new runs via SSE. - Updated the AppSidebar to include links to the new Gateway and Runs pages. - Enhanced FlowNode component to improve status display and styling. - Introduced EmptySection component for consistent empty state presentation. - Updated API utility to include a new endpoint for the runs stream.
This commit is contained in:
@@ -88,6 +88,12 @@ function AgentDetail() {
|
||||
|
||||
useEffect(() => {
|
||||
load();
|
||||
// Reload recent runs whenever any run is dispatched (manual / agent /
|
||||
// GitHub push). Cheap — `load()` is one round-trip.
|
||||
const es = new EventSource(api.runsStreamURL());
|
||||
es.onmessage = () => load();
|
||||
es.onerror = () => {};
|
||||
return () => es.close();
|
||||
// eslint-disable-next-line react-hooks/exhaustive-deps
|
||||
}, [id]);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user