Server-Sent Events (SSE) are not yet implemented in BitzOrcas. SSE is planned as a lightweight alternative to WebSockets for notification streaming and similar one-directional push scenarios.
Planned use cases
| Scenario | SSE suitability |
|---|---|
| Notification inbox updates | ✅ Ideal — server pushes new notifications |
| Audit log streaming | ✅ Good — one-directional log tail |
| Dashboard metrics | ✅ Good — periodic metric push |
| Chat messages | ⚠️ Possible but SignalR better for bidirectional |
Planned endpoint
GET /api/notifications/streamAccept: text/event-stream
→ {"type": "notification", "data": {...}}→ {"type": "notification", "data": {...}}→ {"type": "heartbeat", "data": {}}ASP.NET Core SSE implementation (planned)
app.MapGet("/api/notifications/stream", async (HttpContext ctx) =>{ ctx.Response.Headers.ContentType = "text/event-stream"; ctx.Response.Headers.CacheControl = "no-cache";
// Stream notifications to client await foreach (var notification in notificationStream.ReadAllAsync(ct)) { await ctx.Response.WriteAsync($"data: {JsonSerializer.Serialize(notification)}\n\n"); await ctx.Response.Body.FlushAsync(); }});See also
- Realtime — Overall realtime architecture
- Notifications module — Notification infrastructure