Enterprise-grade financial data platform for ingestion, validation, transformation, lineage tracking, and analytics delivery.
Overview โข Features โข Tech Stack โข Screenshots โข Dashboard โข Architecture โข Quick Start โข API โข Troubleshooting
Data Engineering Pipeline Platform is a production-oriented data platform that ingests financial-style customer, account, transaction, and payment data; validates data quality; transforms datasets through bronze, silver, and gold layers; records lineage; and exposes operational metadata through FastAPI.
The project is designed to resemble a modern financial-institution data platform with orchestration, streaming, batch processing, warehouse modeling, observability, CI/CD, containerization, Kubernetes manifests, and AWS-ready deployment documentation.
Financial organizations depend on trusted data pipelines for reporting, fraud analytics, customer intelligence, payment operations, and regulatory workflows.
When data quality fails, downstream dashboards, risk models, reconciliation jobs, and executive reports become unreliable. This platform demonstrates how enterprise data teams build auditable, monitored, and analytics-ready pipelines using modern data engineering practices.
|
|
|
The platform includes a lightweight FastAPI-powered dashboard for local demos and portfolio walkthroughs. It gives a browser-based view of pipeline execution, quality checks, lineage events, and warehouse tables without requiring a separate frontend framework.
http://localhost:8000/dashboard
The dashboard includes:
- Pipeline run metrics and recent executions
- Data quality result summaries
- Source-to-target lineage events
- Warehouse table inventory
- Quick links to Swagger and Airflow
flowchart LR
A[Financial Source Systems] --> B[Batch CSV Files]
A --> C[Kafka Transaction Events]
B --> D[Airflow DAG]
C --> E[Kafka Consumer]
D --> F[Bronze Raw Zone]
E --> F
F --> G[Data Quality Validation]
G --> H[Silver Validated Zone]
H --> I[PySpark Transformations]
I --> J[Gold Analytics Zone]
J --> K[dbt Models]
K --> L[(PostgreSQL Warehouse)]
L --> M[FastAPI Metadata API]
M --> N[Pipeline Runs]
M --> O[Quality Results]
M --> P[Lineage Events]
M --> Q[Warehouse Tables]
Financial Systems Produce Customer, Account, Transaction, and Payment Data
โ
Batch Files and Kafka Events Enter the Platform
โ
Airflow Orchestrates Batch Workflows
โ
Airflow Injects DAG Run ID Into the Batch Pipeline
โ
Batch Pipeline Writes Operational Metadata to FastAPI/PostgreSQL Tables
โ
Kafka Consumer Handles Streaming Transaction Events
โ
Raw Data Lands in the Bronze Layer
โ
Validation Rules and Quality Checks Execute
โ
Validated Records Move to the Silver Layer
โ
PySpark Jobs Transform and Aggregate Data
โ
Gold Layer Produces Curated Analytics Outputs
โ
dbt Builds Warehouse Models and Reporting Marts
โ
PostgreSQL Stores Warehouse and Metadata Tables
โ
FastAPI Exposes Pipeline, Quality, Lineage, and Warehouse Status
| Step | What Happens |
|---|---|
| 1 | Source systems provide customer, account, transaction, and payment data |
| 2 | Batch ingestion and Kafka streaming bring data into the platform |
| 3 | Bronze raw datasets are created for traceability |
| 4 | Data quality rules validate schema, required fields, uniqueness, and numeric constraints |
| 5 | Silver datasets contain cleaned and validated records |
| 6 | PySpark transformations generate analytical aggregates |
| 7 | dbt models create reporting-ready marts |
| 8 | FastAPI exposes operational metadata for observability |
๐ Folder Structure
data-engineering-pipeline-platform/
โโโ app/ # FastAPI metadata API
โ โโโ api/ # API routes
โ โโโ core/ # Configuration and security
โ โโโ database/ # SQLAlchemy session
โ โโโ models/ # ORM models
โ โโโ schemas/ # Pydantic schemas
โ โโโ services/ # Business logic
โโโ airflow/
โ โโโ dags/ # Airflow orchestration DAGs
โโโ kafka/
โ โโโ consumers/ # Streaming consumers
โ โโโ producers/ # Streaming producers
โ โโโ schemas/ # Event schemas
โโโ spark/
โ โโโ jobs/ # PySpark transformation jobs
โโโ dbt/
โ โโโ models/ # dbt staging and mart models
โโโ great_expectations/ # Data quality project structure
โโโ database/ # Warehouse schema and seed scripts
โโโ data/
โ โโโ sample/ # Sample financial datasets
โ โโโ bronze/ # Raw landed outputs
โ โโโ silver/ # Validated outputs
โ โโโ gold/ # Curated analytics outputs
โโโ kubernetes/ # Kubernetes manifests
โโโ monitoring/ # Monitoring assets
โโโ pipelines/ # Pipeline configuration
โโโ scripts/ # Local runnable pipeline scripts
โโโ tests/ # Unit and integration tests
โโโ Dockerfile
โโโ docker-compose.yml
โโโ Jenkinsfile
โโโ pyproject.toml
โโโ requirements.txt
โโโ README.md
| Requirement | Version |
|---|---|
| Python | 3.11+ |
| Docker | Recommended |
| Git | Any recent version |
| PostgreSQL | Optional for local metadata DB |
| Java | Required for full PySpark runtime |
python -m venv .venv
source .venv/bin/activate
pip install -r requirements.txtFor Windows Git Bash:
python -m venv .venv
source .venv/Scripts/activate
pip install -r requirements.txtuvicorn app.main:app --reloadOpen:
Swagger API: http://localhost:8000/docs
Dashboard: http://localhost:8000/dashboard
python scripts/run_batch_pipeline.pypytestruff check .
black --check .
pytestdocker compose up --buildOpen:
Swagger API: http://localhost:8000/docs
Dashboard: http://localhost:8000/dashboard
Airflow UI: http://localhost:8080/home
curl http://localhost:8000/healthhttp://localhost:8000/dashboard
curl http://localhost:8000/pipelines \
-H "x-api-key: dev-api-key"curl -X POST http://localhost:8000/pipelines/daily_financial_batch/trigger \
-H "x-api-key: dev-api-key"curl http://localhost:8000/pipelines/daily_financial_batch/runs \
-H "x-api-key: dev-api-key"curl http://localhost:8000/pipeline-runs/{run_id} \
-H "x-api-key: dev-api-key"curl http://localhost:8000/quality/results \
-H "x-api-key: dev-api-key"curl http://localhost:8000/lineage \
-H "x-api-key: dev-api-key"curl http://localhost:8000/warehouse/tables \
-H "x-api-key: dev-api-key"
|
|
| Skill Area | Demonstrated Through |
|---|---|
| Data Engineering | Batch ETL, ELT modeling, bronze/silver/gold architecture |
| Backend Engineering | FastAPI metadata APIs, Pydantic schemas, service layer |
| Streaming Systems | Kafka producer and consumer structure |
| Big Data Processing | PySpark transformation job |
| Analytics Engineering | dbt staging and mart models |
| Data Quality | Great Expectations-ready structure and validation rules |
| Platform Engineering | Docker Compose and Kubernetes manifests |
| DevOps | GitHub Actions and Jenkins pipeline |
| Cloud Architecture | AWS EKS, S3, MSK, RDS, CloudWatch strategy |
| Production Thinking | Observability, lineage, testing, security, and troubleshooting |
S3
โโโ raw/
โโโ bronze/
โโโ silver/
โโโ gold/
MWAA / Airflow
โโโ DAG orchestration
MSK
โโโ Streaming transaction events
EKS
โโโ FastAPI metadata service
โโโ Kafka consumers
โโโ Spark jobs
โโโ supporting workers
RDS PostgreSQL
โโโ warehouse tables
โโโ pipeline run metadata
โโโ quality result metadata
โโโ lineage metadata
CloudWatch
โโโ application logs
โโโ pipeline metrics
โโโ operational alerts
Secrets Manager + IAM
โโโ credential and access management
The Docker environment separates application metadata from Airflow orchestration metadata:
| Database | Purpose | Used By |
|---|---|---|
data_platform |
Warehouse tables, pipeline runs, quality results, lineage events | FastAPI, batch pipeline, dbt-style outputs |
airflow_metadata |
DAG runs, task instances, scheduler state, Airflow users | Apache Airflow |
This avoids mixing application/warehouse metadata with Airflow's internal operational tables and more closely resembles production data-platform deployments.
The dedicated Airflow database is created by:
database/init-airflow-db.sql
Airflow executions now feed the dashboard directly. The DAG passes its Airflow run ID into the batch script with PIPELINE_RUN_ID, while the Airflow container uses the application metadata database through DATABASE_URL.
Airflow DAG Run
โ
PIPELINE_RUN_ID='{{ run_id }}'
โ
scripts/run_batch_pipeline.py
โ
pipeline_runs / data_quality_results / lineage_events
โ
FastAPI /dashboard
This keeps Airflow as the orchestrator while the FastAPI dashboard becomes the operational observability layer for application-level pipeline metadata.
|
|
| Layer | Monitoring Focus |
|---|---|
| Airflow | DAG status, retries, duration |
| Kafka | Consumer lag, topic throughput |
| PySpark | Job status, execution time, failure rate |
| Great Expectations | Validation pass/fail status |
| PostgreSQL | Warehouse table freshness and growth |
| FastAPI | Request latency, error rate, health status |
| CI/CD | Build, test, lint, and security scan status |
Ruff E402: Module level import not at top of file
This usually happens when path setup code appears before imports.
Run:
ruff check . --fixIf needed, keep path setup before project imports and mark project-level imports:
from app.database.session import SessionLocal # noqa: E402ModuleNotFoundError for app imports
Run commands from the repository root.
For macOS/Linux:
export PYTHONPATH=.For Windows PowerShell:
$env:PYTHONPATH="."For Windows Git Bash:
export PYTHONPATH=.API key authentication fails in Swagger
Use this value in the x-api-key field:
dev-api-key
Or update the value in your local environment configuration.
PostgreSQL connection refused
Check whether services are running:
docker compose psRestart containers:
docker compose up --buildKafka service unavailable
Start the Kafka service through Docker Compose:
docker compose up kafkaIf the project uses a separate broker dependency, start the full stack:
docker compose up --buildPySpark job fails locally
Confirm Java is installed:
java -versionThen verify PySpark dependencies:
python -c "import pyspark; print(pyspark.__version__)"Swagger docs load but endpoints return empty data
Run the batch pipeline first:
python scripts/run_batch_pipeline.pyThen refresh:
http://localhost:8000/docs
rm -rf .pytest_cache .ruff_cache __pycache__
rm -f local_metadata.db
python -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
ruff check .
black --check .
pytest
python scripts/run_batch_pipeline.py
uvicorn app.main:app --reloadFor Windows Git Bash, activate with:
source .venv/Scripts/activate| Priority | Improvement |
|---|---|
| High | Add OpenLineage and Marquez integration |
| High | Add Prometheus /metrics endpoint |
| Medium | Add Grafana dashboard JSON |
| Medium | Add Terraform infrastructure for AWS |
| Medium | Add Helm charts |
| Low | Add Spark-on-Kubernetes job operator manifests |
| Low | Add dbt docs publishing workflow |
| Low | Add S3-backed local development mode |
This project is licensed under the MIT License.








