Skip to content

feat(consumoor): add kafka-to-clickhouse consumoor pipeline#747

Open
samcm wants to merge 17 commits intomasterfrom
feat/event-manifest-vector-pipeline
Open

feat(consumoor): add kafka-to-clickhouse consumoor pipeline#747
samcm wants to merge 17 commits intomasterfrom
feat/event-manifest-vector-pipeline

Conversation

@samcm
Copy link
Member

@samcm samcm commented Feb 16, 2026

Summary

Adds a new xatu consumoor command and service implementation under pkg/consumoor that consumes Kafka DecoratedEvent messages and writes flattened rows directly to ClickHouse.
Registers flattener implementations for beacon, canonical, execution, consensus, MEV relay, node record, and libp2p events, including conditional routing and validator fan-out behavior.
Includes consumoor config, metrics, metadata extraction, and routing/writing infrastructure.

Changes

  • Added the consumoor CLI command, config loading/overrides, and an example config file.
  • Implemented the consumoor runtime: Kafka consumer group handling, router/metadata extraction, ClickHouse batched writer, Prometheus metrics, and flattener registry integration.
  • Added generic and libp2p flattener logic with event registry coverage and unit tests for metadata extraction, routing predicates, validator fan-out, libp2p enrichment, and sync committee/sync aggregate mutators.

@samcm samcm requested a review from Savid as a code owner February 16, 2026 03:18
samcm added 16 commits February 16, 2026 13:31
…inator

Replaces at-most-once Kafka offset handling with a centralized commit
coordinator that defers offset commits until ClickHouse writes succeed.

- Add FlushAll to Writer interface for coordinator-driven flushes
- Blocking Write() propagates CH backpressure to Kafka consumption
- Non-destructive flush: batches preserved on CH failure for retry
- Disable Kafka auto-commit; coordinator owns flush+mark+commit cycle
- Add commitInterval config (default 5s) for commit cycle timing
- Add commits_total, commit_errors_total, flush_all_duration_seconds metrics
Cover happy path, empty pending no-op, FlushAll failure with retry,
failure ordering preservation, multi-topic/partition highwater,
Stop final flush, and interval-triggered commits.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant