RETURN TO HOME PORTFOLIO
25 CASE STUDIES CATALOG
ENGINEERING JOURNAL // DATAPULSE PLATFORM

THE 25 CASE STUDIES

A human engineering journal documenting my actual journey building **DataPulse** — from operational PostgreSQL application databases to PySpark distributed processing, Delta Lake time-travel, and Data Black Box incident replay.

CASE #01ACTUAL

Why Moving Data From A to B Was the Easy Part

Designing DataPulse: From Monolithic Application DB to Data Reliability Platform

Understanding why direct operational database queries fail at analytical scale and designing a decoupled processing architecture.

OLTP vs OLAP WorkloadsMedallion Data Lakehouse ArchitectureResource Lock Contention
Read Investigation
CASE #02ACTUAL

Designing the Database That Watches Other Databases

Relational Schema Modeling for Data Engineering Metadata

Structuring a clean relational model to track pipeline runs, table snapshots, dataset metadata, and schema version changes.

Metadata State TrackingACID State TransitionsRelational ERD Modeling
Read Investigation
CASE #03ACTUAL

Writing Ingestion Scripts That Don't Crash at 2 AM

Robust Python Batch Ingestion with Server-Side Cursors & Backoff Retries

Preventing Out-of-Memory crashes and transient connection failures in Python ETL ingestion using server-side cursors and exponential backoff.

Server-Side CursorsExponential Backoff & JitterConnection Pooling
Read Investigation
CASE #04ACTUAL

Why I Stopped Re-Processing Millions of Rows Every Night

Incremental Extraction Architecture with High-Watermark State Management

Eliminating full table re-scans by implementing watermark-based incremental ETL and append-only staging writes.

High-Watermark TrackingIncremental vs Full LoadIdempotent Watermarks
Read Investigation
CASE #05ACTUAL

Beyond GROUP BY: How Window Functions Saved Me From 5-Way Self-Joins

Advanced Analytical SQL with DENSE_RANK, LAG, and LEAD

Replacing complex self-joins and subqueries with SQL window functions to compute state changes and tenant rankings in a single pass.

SQL Window FunctionsPartitioning & OrderingLAG/LEAD State Changes
Read Investigation
CASE #06ACTUAL

Finding the Missing Index That Saved Query Runtime

PostgreSQL B-Tree Index Optimization & EXPLAIN ANALYZE Execution Plans

Diagnosing sequential disk scans on 5M row tables and adding targeted composite B-Tree indexes to drop query runtime from 12s to 4ms.

B-Tree Composite IndexesSequential Scan vs Index ScanEXPLAIN ANALYZE Diagnostics
Read Investigation
CASE #07ACTUAL

Airflow Said SUCCESS, but the Data Was Completely Wrong

Data Quality Validation, Assertion Frameworks, and DAG Circuit Breakers

Preventing silent data corruption by embedding automated assertions, row-count validations, and circuit breakers into Airflow pipelines.

Data Quality AssertionsCircuit Breaker PatternSilent Data Corruption
Read Investigation
CASE #08ACTUAL

What Happens When Upstream Drops a Column Without Telling You?

Schema Drift Management, Contract Testing, and Pydantic Validation

Shielding ingestion pipelines from unexpected upstream breaking changes using strict data contracts and Pydantic schema validation.

Schema DriftData ContractsPydantic Validation
Read Investigation
CASE #09ACTUAL

Organizing the Chaos: Building Bronze, Silver, and Gold in Azure

ADLS Gen2 Directory Partitioning and Lakehouse Storage Architecture

Structuring Azure ADLS Gen2 containers into clean Bronze (raw), Silver (cleansed), and Gold (curated) Medallion storage layers.

Medallion ArchitectureADLS Gen2 StorageDirectory Hive Partitioning
Read Investigation
CASE #10ACTUAL

Why Parquet Saved Storage Volume and Sped Up Queries

Columnar Storage Mechanics, Dictionary Encoding, and Snappy Compression

Benchmarking CSV, JSON, and Apache Parquet file formats to prove an 82% reduction in storage footprint and 10x faster analytical query scans.

Row vs Columnar StorageDictionary EncodingSnappy Compression
Read Investigation
CASE #11ACTUAL

I Partitioned the Data Wrong. Here's What Happened.

Resolving the Small File Problem and Optimizing File Compaction

Fixing high query latency caused by over-partitioning data into 150,000 tiny 4KB Parquet files using file compaction and partition tuning.

Small File ProblemPartition CardinalityFile Compaction
Read Investigation
CASE #12EXPERIMENT

Schema Inference Is Convenient Until Your Spark Job Crashes

PySpark StructType Explicit Schemas & Catalyst Optimizer

Why relying on PySpark's automatic inferSchema=True forces extra full scans over raw data files and how explicit schemas eliminate discovery latency.

Catalyst Optimizer StagesExplicit StructType SchemasSchema-on-Read Mechanics
Read Investigation
CASE #13EXPERIMENT

Where Did All That Shuffle Come From?

Reducing Network Shuffle Volume in PySpark via Predicate Pushdown and Column Pruning

Joining un-filtered DataFrames with 45 columns flooded network interfaces with massive Shuffle Read bytes and executor disk spill.

Narrow vs Wide TransformationsNetwork Shuffle ManagerPredicate Pushdown
Read Investigation
CASE #14EXPERIMENT

I Added More Partitions and Made the Pipeline Slower

Task Scheduling Overhead and Driver Bottlenecks in Distributed Spark Jobs

Investigating why repartitioning 2 GB of data into 5,000 partitions caused Driver scheduling bottlenecks and increased overall job execution duration.

Task Scheduling OverheadPartition GranularityDriver Bottleneck
Read Investigation
CASE #15EXPERIMENT

Replacing Network Shuffle With Broadcast Joins

Eliminating Shuffle in PySpark Using Broadcast Hash Joins

Eliminating cluster network shuffle when joining large fact datasets with small dimension lookup tables using PySpark `broadcast()`.

Broadcast Hash JoinSort Merge JoinDriver Memory Limits
Read Investigation
CASE #16EXPERIMENT

Most Workers Finished Fast. The Last Worker Took Forever.

Mitigating Data Skew in PySpark Using Salting Techniques

Solving severe execution skew where 99% of Spark tasks finished in seconds while 1 task straggler stalled for 25 minutes due to tenant hot-keys.

Data Skew & StragglersSalt KeysKey Distribution Uniformity
Read Investigation
CASE #17EXPERIMENT

I Added .cache() and Made the Pipeline Slower

Spark Memory Management, Storage Eviction, and Cache Anti-Patterns

Uncovering why liberal use of `.cache()` caused executor disk spill, garbage collection pauses, and degraded overall PySpark job runtime.

Spark Memory FractionsStorage vs Execution MemoryCache Eviction Overhead
Read Investigation
CASE #18ACTUAL

Recovering From a Corrupted Data Update With Delta Lake Time Travel

Delta Lake Transaction Log Architecture and One-Command Incident Recovery

Recovering from a bug that accidentally updated 500,000 status values to NULL using Delta Lake transaction logs and Time Travel in 12 seconds.

Delta Log (_delta_log)ACID Transaction LogTime Travel Queries
Read Investigation
CASE #19ACTUAL

What Happens When an Airflow Task Fails Halfway Through?

Idempotent Pipeline Design and Dynamic Partition Overwrite Mechanics

Preventing duplicate data writes and partial state corruption during task retries using idempotent pipeline architecture and dynamic partition overwrites.

Pipeline IdempotencyDynamic Partition OverwriteAtomic Output Writes
Read Investigation
CASE #20ACTUAL

Hardcoding Credentials in Code Is a Security Disaster

Securing Azure Data Pipelines with Key Vault and Managed Identities

Eliminating plain-text secrets and access keys from codebases by integrating Azure Key Vault, Managed Identities, and secret scrubbing.

Azure Key Vault IntegrationManaged Identities (MSI)Zero Trust Security
Read Investigation
CASE #21ACTUAL

From Data Lake to Cloud Warehouse: Loading and Querying Snowflake

High-Throughput Data Ingestion and Semi-Structured JSON Parsing in Snowflake

Building high-performance data loading pipelines into Snowflake using External Stages, COPY INTO, and VARIANT semi-structured parsing.

Snowflake External StagesCOPY INTO Bulk LoadingVARIANT Data Type
Read Investigation
CASE #22ACTUAL

The Data Didn't Break the Pipeline. The Data Broke the Business.

Data DNA Fingerprinting and Cryptographic Duplicate Detection

Detecting semantic data corruption and duplicate business events using SHA-256 Data DNA fingerprinting at the ingestion boundary.

Data DNA FingerprintingSHA-256 HashingSemantic Data Corruption
Read Investigation
CASE #23ACTUAL

Tracking an Error Backward Through Multiple Transformation Layers

Data Lineage Propagation and End-to-End Audit Trail Instrumentation

Tracing corrupted output metrics back to their exact source Bronze JSON raw payload using explicit lineage metadata propagation.

End-to-End Data LineageOpenLineage StandardsAudit Metadata Injection
Read Investigation
CASE #24ACTUAL

Can We Reproduce Yesterday's Production Pipeline Bug?

Building the Data Black Box Incident Replay Engine

Reconstructing historical pipeline state and replaying exact raw dataset snapshots against modified code to verify production bug fixes.

Data Black Box ArchitectureTemporal Incident ReplayIsolated Sandbox Replay
Read Investigation
CASE #25ACTUAL

From Writing Functions to Engineering Systems: 25 Case Studies Later

Architectural Reflection, Trade-Off Frameworks, and Data Platform Mastery

Synthesizing lessons from building DataPulse — moving from individual code scripts to resilient, observable, and cost-optimized data platforms.

Systems Thinking in DataArchitectural Trade-Off MatrixData Engineering Maturity Model
Read Investigation