How ajxavier/modern-local-data-lakehouse works
This repository demonstrates a local real-time market-data lakehouse: Binance trades are published to Kafka, transformed and persisted by a Spark streaming job, then queried through Trino. A separate Airflow DAG checks service health, and a sampled batch job demonstrates retail-data processing. Relationships are based on the README and shown excerpts; unsampled infrastructure configuration is not inferred beyond documented capabilities.
Main entry points: kafka_stream.py Trade Stream Job · read_sales.py Retail Batch ETL · lakehouse_pipeline.py Health Checks · binance_kafka_producer.py Trade Producer
Components 12
Market Ingestion
- Trade Producer
ingestion/binance_kafka_producer.py - Kafka Topic
Spark Processing
- Trade Stream Job
pyspark/jobs/kafka_stream.py - Retail Batch ETL
pyspark/jobs/read_sales.py
Lakehouse Services
- Iceberg Tables
- MinIO Storage
- Gravitino Catalog
Query and Operations
- Trino SQL Engine
- SQL Session
Binance_iceberg.session.sql - Health Checks
airflow/dags/lakehouse_pipeline.py
Other components
- Binance WebSocket
- SQL User
Connections 15
- Binance WebSocket → Trade Producer: sends trades
README.md - Trade Producer → Kafka Topic: publishes events
ingestion/binance_kafka_producer.py - Trade Stream Job → Kafka Topic: reads events
pyspark/jobs/kafka_stream.py - Trade Stream Job → Gravitino Catalog: configures catalog
pyspark/jobs/kafka_stream.py - Trade Stream Job → Iceberg Tables: writes table
pyspark/jobs/kafka_stream.py - Iceberg Tables → MinIO Storage: stores data
README.md - Retail Batch ETL → MinIO Storage: reads and writes
pyspark/jobs/read_sales.py - Retail Batch ETL → Gravitino Catalog: configures catalog
pyspark/jobs/read_sales.py - Retail Batch ETL → Iceberg Tables: writes table
pyspark/jobs/read_sales.py - SQL User → SQL Session: runs queries
README.md - SQL Session → Trino SQL Engine: queries through
README.md - Trino SQL Engine → Iceberg Tables: queries tables
README.md - Health Checks → Kafka Topic: checks health
airflow/dags/lakehouse_pipeline.py - Health Checks → Trino SQL Engine: checks health
airflow/dags/lakehouse_pipeline.py - Health Checks → Trade Stream Job: checks service
airflow/dags/lakehouse_pipeline.py