You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A production-grade streaming data pipeline built entirely with open-source tools. Generates synthetic e-commerce orders, streams them through Kafka, aggregates in real-time, and visualises on a live dashboard.
Tech Stack
Layer
Technology
License
Event Streaming
Apache Kafka 3.7 (KRaft, no Zookeeper)
Apache 2.0
Stream Processing
Python + kafka-python (custom tumbling windows)
Apache 2.0
Analytics DB
ClickHouse 23.8
Apache 2.0
API / Producer
Go + Gin
MIT
Orchestration
Dagster
Apache 2.0
Monitoring
Prometheus
Apache 2.0
Dashboards
Grafana OSS
AGPL-3.0
Frontend
React + TypeScript + Recharts + Tailwind
MIT
Container Runtime
Docker Compose
Apache 2.0
Architecture
graph LR
A[Go Producer<br/>:8080] -->|orders| B[Kafka<br/>KRaft]
A -->|~5% malformed| C[orders-dlq]
B --> D[Stream Processor<br/>Python]
D -->|invalid records| C
D -->|aggregated windows| E[ClickHouse<br/>:8123]
A -->|query metrics| E
E --> F[React Dashboard<br/>:3002]
E --> G[Grafana<br/>:3001]
E --> H[Dagster<br/>:3000]
A -->|/metrics| I[Prometheus<br/>:9090]
I --> G
Loading
Kafka — Topics
Services & Ports
Service
Port
Description
React Dashboard
3002
Live analytics frontend
Go API
8080
REST API + order generator
Go Metrics
8080/metrics
Prometheus scrape endpoint
Kafka UI
8090
Browse topics & messages
Dagster
3000
Pipeline orchestration
Grafana
3001
Pre-built dashboards (admin/admin)
Prometheus
9090
Metrics storage
ClickHouse HTTP
8123
Direct SQL queries
Prerequisites
Docker Desktop ≥ 4.x with at least 8 GB RAM allocated
Docker Compose v2 (docker compose command)
Quick Start
# 1. Clone the repo
git clone https://github.com/SriramAtmakuri/DataStream.git
cd DataStream
# 2. Start all services
docker compose up --build
# 3. Open the dashboard — navigate to port 3002 in your browser
Data starts flowing immediately. The stream processor writes aggregated windows to ClickHouse every 1 minute (orders_per_minute) and every 5 minutes (revenue_by_region, top_products). The React dashboard polls every 5 seconds.
API Endpoints
POST /api/orders Create a single order manually
GET /api/orders/stats Generator status
GET /api/metrics/orders-per-minute Orders per minute (last 60 min)
GET /api/metrics/revenue-by-region Revenue grouped by region (last 1h)
GET /api/metrics/top-products Top 10 products by revenue (last 1h)
GET /api/metrics/error-rate Failed order rate (last 5 min)
GET /health Health check
GET /metrics Prometheus metrics