Performance · 2 min read · Nov 2026

How I cut a healthcare pipeline's processing time by more than 70%

Pawan Yandapalli · Data engineer

At Molina Healthcare, claims, member, provider, enrollment and payment data came from more than 20 systems into one lakehouse on Azure Databricks, with Snowflake downstream. Every refresh was slow, and processing time became the thing everyone waited on.

There wasn't one fix. The 70% came from a set of smaller changes, each aimed at a specific kind of waste.

1. Partition for how the data is read

Partitioning by the columns that downstream jobs actually filter on meant Spark could skip whole directories instead of scanning everything.

2. Let Spark adapt at runtime

Adaptive Query Execution re-plans a query while it runs, using real statistics: it merges tiny shuffle partitions, switches join strategies when one side turns out to be small, and splits skewed partitions. Turning it on removed a class of problems I would otherwise have tuned by hand, job by job.

3. Z-Order the most-filtered tables

For the Delta tables that were filtered most often, Z-Ordering co-located related values in the same files, so data skipping could prune more files per query.

4. Cache what gets reused, and compact small files

Datasets reused across several steps were cached once instead of being recomputed. Small files, a common side effect of frequent incremental loads, were compacted so each task read fewer, larger files.

5. Stop paying for idle compute

Faster jobs are only half the story. I resized the Databricks clusters, moved work to job compute and set up autoscaling so we weren't paying for capacity we didn't use. On the Snowflake side, query history and query profiles showed which warehouses were oversized, and I right-sized them.

What I'd tell someone starting this work

  • Measure end to end before touching anything, so you know which stage dominates.
  • Fix layout (partitioning, file sizes, Z-Order) before reaching for bigger clusters.
  • Change one thing at a time and re-measure, or you won't know what worked.

The patterns above are rebuilt on synthetic data in my public repo: github.com/pawanyandapalli7/data-engineer-portfolio