sse

command
v0.4.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 31, 2026 License: MIT Imports: 7 Imported by: 0

Documentation

Overview

Command sse streams the tq journal as Server-Sent Events — the proof-of-concept for live dashboards without a polling client.

Usage:

go run ./examples/sse --db tasks.db --addr :8090
curl -N localhost:8090/events            # replay, then follow
curl -N 'localhost:8090/events?after=42' # only newer facts

Each event carries the fact JSON, with the journal sequence as the SSE id so a reconnecting client can resume where it left off (`Last-Event-ID` header maps to `after`). PoC scope: one poller per connection; production would fan out from a single tailer.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL