-
Notifications
You must be signed in to change notification settings - Fork 4
docs: add worker event streaming feature doc #1648
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
Questions that still need answering:
|
LNSD
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM ✅
| ## Event Reference | ||
|
|
||
| ### Event Envelope | ||
|
|
||
| All events share a common envelope: | ||
|
|
||
| ```json | ||
| { | ||
| "event_id": "uuid-v4", | ||
| "event_type": "sync.progress", | ||
| "event_version": "1.0", | ||
| "timestamp": "2026-01-15T10:30:00Z", | ||
| "source": { | ||
| "worker_id": "worker-01" | ||
| }, | ||
| "payload": { ... } | ||
| } | ||
| ``` | ||
|
|
||
| ### `sync.progress` Payload | ||
|
|
||
| ```json | ||
| { | ||
| "job_id": 12345, | ||
| "dataset": { | ||
| "namespace": "ethereum", | ||
| "name": "mainnet", | ||
| "manifest_hash": "2dbf16e8..." | ||
| }, | ||
| "table_name": "blocks", | ||
| "progress": { | ||
| "start_block": 18900000, | ||
| "current_block": 19000000, | ||
| "files_count": 100, | ||
| "total_size_bytes": 50000000 | ||
| } | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Event formats should live in the code. We can keep it here for now, but implementation details (such as code and formats) should live in the code.
No description provided.