· 8 min
dbt Microbatch: Incremental Models Built by Time Batch
How the dbt microbatch strategy works: event_time, batch_size, lookback, targeted backfills, retrying failed batches, and when it beats a hand-written filter.
- #dbt
- #incremental-models
Data Engineering Blog
142 illustrated deep-dives written from production data work — covering warehouses, ETL/ELT pipelines, cost reduction, data modeling, and streaming systems.
142 entries · 47 stacks · beginner to staff level
§ dbt
How the dbt microbatch strategy works: event_time, batch_size, lookback, targeted backfills, retrying failed batches, and when it beats a hand-written filter.
Read the entry →Showing 142 articles
· 8 min
How the dbt microbatch strategy works: event_time, batch_size, lookback, targeted backfills, retrying failed batches, and when it beats a hand-written filter.
· 9 min
Use dbt model contracts, versions, access levels and deprecation dates to change a widely used model without breaking the dashboards and teams that use it.
· 9 min
How dbt Projects on Snowflake works: deploying a DBT PROJECT object, EXECUTE DBT PROJECT, scheduling with tasks, Slim CI with IMPORTS, roles and limits.
· 9 min
The dbt-snowflake configs that matter in production: per-model warehouses, query tags for cost attribution, grants, dynamic tables and incremental strategies.
· 10 min
dbt v2, the Rust engine once called Fusion, is GA. What changes from v1, how to check a project with dbt-autofix, and a safe side-by-side migration plan.
· 17 min
When sports feeds assign different IDs to one fixture, canonical match records, provider mappings, and guarded updates prevent duplicate data.
· 10 min
Use Snowflake AI functions in batch pipelines: filter before you classify, constrain the labels, summarize with AI_AGG, and keep the token bill visible.
· 9 min
Set up Snowflake account and custom budgets, tag-based limits, threshold actions and cost anomaly alerts so a runaway pipeline shows up in days, not invoices.
· 10 min
Gen2 is now the default and Adaptive Warehouses are GA. How to test a move, what changed in QAS defaults, and when to keep sizing warehouses yourself.
· 9 min
Define metrics once in a Snowflake semantic view, query them with plain SQL or Cortex Analyst, and add materializations without forking definitions.
· 6 min
How to cut your AWS Redshift bill by optimizing Serverless base capacity, managing RPUs, using RA3 instances, and tuning Workload Management (WLM).
· 4 min
A comprehensive TCO guide: pricing equations, real-world workload cost models, and how to use our interactive data stack cost estimator.
· 4 min
A pragmatic comparison: Databricks for Lakehouse/Spark/ML vs BigQuery for Serverless/SQL-native analytical workflows on GCP.
· 7 min
The ELT decision as it plays out: MAR pricing versus infrastructure you operate, what happens when a connector breaks, and when to write a custom extractor.
· 8 min
Where a real-time OLAP engine beats a cloud warehouse and where it loses: latency at high concurrency, ingest patterns, joins at scale, and governance gaps.
· 8 min
The honest split between dbt Core and dbt Cloud: what Cloud adds over CI plus an orchestrator, what seats cost, and when self-hosting stops being cheaper.
· 8 min
Flink vs Spark Structured Streaming in production: how each holds state, their real latency floors, and why your existing batch stack usually decides it.
· 7 min
The architecture differences that change operations: segment storage vs partition-as-log, tiered offload, tenant isolation, and when leaving Kafka is a mistake.
· 7 min
What each file format is built for: columnar analytics, Hive-native storage, and row-oriented streaming, plus the compression and small-file realities.
· 8 min
A decision guide, not a benchmark: what the expression API and lazy engine buy you, which pandas jobs will not get faster, and the gaps that remain.
· 9 min
MLOps through a data engineering lens: what feature stores actually solve, why training pipelines are just DAGs, and the skills that transfer.
· 9 min
How the triggerer frees workers: why classic sensors hold a slot, FileSensor vs deferrable waits, and the habits that keep deferred tasks from sitting forever.
· 6 min
ORDER BY is the only index that matters, one-row inserts explode parts, mutations rewrite data, and ClickHouse is not a warehouse stand-in. Batch the writes.
· 6 min
Software-defined assets vs Airflow tasks, how partitions change backfills, asset checks versus dbt tests, and why warehouse credentials belong in resources.
· 11 min
Schema plus SLAs as a producer-owned contract: fail the write path when grain or freshness breaks, instead of finding out in a warehouse test afterwards.
· 11 min
How incremental dbt models actually write: unique_key as merge grain, is_incremental filters, lookback windows, and late arrivals that silently drop rows.
· 5 min
A green CI build on python:3.11-slim:latest became a Saturday outage when prod pulled a new digest. Pin the bytes and promote the same image.
· 8 min
Beyond chatbots: how data engineers use LLMs for entity extraction, data classification, documentation generation, and pipeline triage, with cost controls.
· 10 min
Model Context Protocol as a tool bus for warehouse and pipeline context: read-only roles, no DROP, and prompt injection that hides in table comments.
· 10 min
How Dynamic Tables actually refresh: TARGET_LAG, the warehouse that pays for it, streams vs DT, and why I still keep dbt for gold.
· 10 min
What a micropartition is, how clustering and sargable filters prune, why wrapping columns and SELECT * blow the scan, and how to read partitions_scanned.
· 10 min
CREATE STREAM, consume it in a Task MERGE, handle stale offsets, and know when Airflow should still orchestrate dbt and everything outside Snowflake.
· 10 min
CREATE … CLONE shares micropartitions until someone writes. How storage grows, cloning at a timestamp, clones in CI, and why gold is never mutated via a clone.
· 9 min
How to use AI coding assistants for pipeline work: SQL generation, dbt refactoring, debugging, and docs, plus the failure modes to watch for.
· 6 min
OneLake shortcuts are not a copy job, capacity units are shared, and a Power BI refresh can queue a Spark notebook. Fabric is not rebranded Synapse.
· 5 min
Eager Polars still OOM’d a 12 GB box. Lazy scan, streaming collect, and leaving most pandas jobs alone, plus when DuckDB or Spark is the right next step.
· 5 min
A flow is Python. A deployment is what actually runs. Work pools are where. Prefect will call an empty extract a success unless you raise.
· 10 min
An honest comparison of vector storage options for AI workloads, and why the right answer is often the database you already run.
· 6 min
FlowFiles pile up when a downstream processor stalls and provenance has its own disk. Set queue limits, watch both repositories, and skip NiFi as a Kafka bus.
· 6 min
A typed Dataset[T] job caught a column I had been silently dropping in PySpark. You still have to read Scala; you do not have to write every job in it.
· 5 min
Trino stores nothing. A federated SELECT * on prod Postgres is a database incident. Use Iceberg for the lake, and keep interactive SQL off OLTP.
· 6 min
Processing time lies after a restart and watermarks drop late events on purpose. Checkpoints recover, savepoints migrate, Kafka EOS does not upsert Postgres.
· 6 min
Copy-on-write versus merge-on-read, incremental pulls versus snapshots, compaction as a job you schedule, and why one table gets one writer and one format.
· 6 min
A BI scan froze autovacuum, the replication slot kept WAL, and the disk hit 91%. Read the plan, manage bloat, and keep CDC from filling the volume.
· 9 min
Retrieval-augmented generation is an ETL problem wearing an AI costume. How to build a production RAG ingestion pipeline with the skills you already have.
· 5 min
Green sync, empty destination, raw JSON versus typed silver, self-host versus Cloud, and why Airbyte does not replace dbt.
· 12 min
A practical guide to the Azure data platform: when to use Data Factory, what happened to Synapse, and how Microsoft Fabric changes the picture.
· 6 min
Write-once Beam is real. The Dataflow bill is vCPU-hours plus Shuffle plus Streaming Engine, and Spark is cheaper if the team already writes Spark.
· 6 min
A nested `items` array hit gold twice and finance saw 1.9x revenue. Land the document raw, explode once in silver, and do not pretend Mongo is the warehouse.
· 6 min
ALLOW FILTERING timed out the coordinator and a quick report full-scanned the cluster. Model the query first and keep Cassandra off the warehouse path.
· 5 min
Monthly active rows surprise you, warehouse writes have their own bill, a custom extractor can beat a connector, and Fivetran still does not replace dbt.
· 6 min
NameNode small-file pauses, the Hive metastore as the real lock-in, and why distcp-plus-EMR keeps the same tables. Iceberg is the exit, not a new cluster.
· 11 min
S3, Glue, Kinesis, Redshift, Athena, EMR, Lambda. A map of the AWS data services, what each is actually for, and the combinations that work in practice.
· 5 min
Four checks (freshness, volume, schema, uniqueness), a written fail-versus-ticket policy, why always-red tests get ignored, and dbt vs GX vs a vendor.
· 5 min
Brokers are stateless. BookKeeper holds the log. Pulsar wins on tenant isolation and geo. A healthy Kafka cluster is not a fashion problem.
· 6 min
We trained on warehouse snapshots and served from Redis. After TTL eviction and a stampede the model looked broken. Online features are a cache.
· 5 min
Dynamic mapping stored amount as text and a terms agg became the executive number. Idempotent ids, a reindex fallback, and warehouse math in the warehouse.
· 8 min
How to use Cortex LLM functions inside pipelines (COMPLETE, CLASSIFY, EMBED) with cost controls, schema checks, retries, and a warehouse-native RAG shape.
· 6 min
A SQLMesh plan is a snapshot diff you apply and virtual environments share unchanged tables. dbt defer is CI, not isolation, and you still need an orchestrator.
· 6 min
Click-ops Snowflake grants will not exist in the next account. Modules for warehouse plus IAM, secrets out of state, and Terraform for anything that lasts.
· 13 min
An honest comparison of the three major Python orchestrators: where each one shines, where each one hurts, and a simple decision rule.
· 5 min
Airflow and Spark can spawn unbounded pods, requests and limits decide eviction, and MWAA or Databricks is sometimes the right way to not run K8s.
· 6 min
COMPOUND sort keys and DISTKEY still decide scans on RA3, VACUUM and ANALYZE are not optional, and Spectrum SELECT * is an S3 bill.
· 5 min
Q2 revenue had three values depending on the workbook. LookML, MetricFlow, or a Power BI dataset can hold the metric, but they do not replace dbt.
· 15 min
Snowflake Time Travel and Fail-safe in practice: retention, UNDROP, cloning at a timestamp, why storage follows churn, and a restore runbook you can test.
· 8 min
A beginner-friendly guide to your first ETL pipeline: extract from an API, transform with pandas, and load into a database, scheduled with Apache Airflow.
· 12 min
When to use Snowflake-managed Iceberg vs native tables: external volumes, catalogs, deletion vectors, and the interoperability jobs Iceberg actually wins.
· 8 min
Deduplication, running totals, sessionization, period-over-period comparisons, and top-N per group, plus frames, pitfalls, and live playground queries.
· 11 min
An honest head-to-head: SQL warehousing vs Spark lakehouse, Iceberg interoperability, Cortex vs Mosaic, and when you need both.
· 9 min
A practical framework for adding data quality checks to Python pipelines: what to check, where to check it, and when to fail loudly vs quarantine.
· 10 min
The pricing models decide the architecture: warehouse-hours versus on-demand scans, plus multi-cloud vs GCP-native gravity.
· 9 min
Why DuckDB replaced pandas in many pipelines: query Parquet and CSV files directly with SQL, at speeds that embarrass much bigger tools.
· 12 min
When to run Kafka (or MSK) versus Kinesis Data Streams: partitions vs shards, replay, multi-cloud, and the hidden cost of “managed.”
· 9 min
BigQuery charges by bytes scanned. Learn how partitioning and clustering cut scan costs by 90%+, and the query patterns that silently bypass them.
· 9 min
What the lakehouse actually is, how Delta Lake adds ACID transactions to cheap object storage, and the medallion architecture in practice.
· 17 min
Warehouse sizing, auto-suspend, clustering, ACCOUNT_USAGE queries, and resource monitors. Estimate the bill from usage before you change prod.
· 5 min
Set up a dbt project from scratch: staging models, marts, tests, and documentation, with the project structure conventions used by real teams.
· 11 min
The mental model every data engineer needs before touching Kafka: how topics, partitions, offsets, and consumer groups work together.
· 9 min
Learn the PySpark DataFrame API, understand lazy evaluation and partitions, and avoid the classic mistakes that make Spark jobs slow.
· 10 min
A four-layer Airflow testing setup: parse checks, DAG structure tests, task unit tests with mocked hooks, and dag.test() runs against local infrastructure.
· 12 min
Where the memory actually goes in a pandas job, how much dtype selection and Arrow-backed strings really save, and when to stop loading and start streaming.
· 12 min
Snowpipe file ingestion vs Snowpipe Streaming: real latency ranges, the credit math per million rows, and how to pick without over-engineering.
· 11 min
Practical patterns for expand, expand_kwargs, and partial in Airflow: size and batch a fan-out safely without overwhelming the scheduler and metadata DB.
· 22 min
The feature lists have converged. What still differs is metadata structure, catalog architecture, and engine support, and those decide which format fits.
· 12 min
Layered testing for Python data pipelines: pure transform tests, DuckDB as a warehouse fake, property-based invariants, and what runs in CI vs production.
· 13 min
Working SQL for every SCD type, the point-in-time join most Type 2 builds get wrong, and a straight account of which types are worth the maintenance.
· 12 min
Moving from per-column masking to tag-based masking and mapping-table row access policies, with the performance traps and audit queries that prove coverage.
· 14 min
A component-by-component map from Synapse to Fabric, the T-SQL and workload management gaps that bite, and the order I move things in to keep risk low.
· 14 min
Postgres CDC with Debezium in production: how the replication slot fills your disk, snapshotting a large table without locks, and replay-safe change apply.
· 10 min
Move cross-team DAG dependencies from padded cron offsets to dataset triggers, with conditional scheduling, naming rules, and the failure modes to expect.
· 10 min
What DLT genuinely buys you, how expectations and streaming tables behave in production, and the four situations where I still write plain Spark jobs instead.
· 13 min
Dataflow vs Dataproc on GCP in production: what Beam buys you, how the two billing models differ, and the team traits that decide the choice.
· 13 min
How to build one Data Factory pipeline that ingests 300 tables instead of 300 pipelines, and how to size integration runtimes so the bill and the SLA both work.
· 12 min
A production migration guide: the expression API, lazy frames and query optimization, null versus NaN semantics, and pandas patterns with no polars twin.
· 11 min
How Snowflake secure data sharing works across accounts, regions, and clouds, when to use a reader account, and governance that keeps a share from leaking.
· 13 min
Joins are not the expense they were in 2015. What a wide denormalized table really costs in storage, rebuild time, and history, and the hybrid I ship instead.
· 12 min
The Airflow 3 changes that break real DAGs: the Task SDK boundary, optional logical_date, removed context keys, DAG versioning, and an upgrade checklist.
· 12 min
The Connect settings that decide whether connectors survive real data: converter choice, error tolerance with a DLQ, SMT limits, and sizing workers.
· 11 min
Taking 30 percent off a Databricks bill in a week: drop all-purpose clusters for jobs, price spot properly, test Photon per workload, rank system.billing.
· 13 min
Real timings and costs comparing single-node DuckDB against a Spark cluster, and why the crossover point is decided by shuffle volume rather than raw data size.
· 10 min
Snowpark Python vs plain SQL in Snowflake: lazy DataFrames, UDF serialization costs, and the four workloads where Python earns its place.
· 12 min
DISTINCT, GROUP BY, ROW_NUMBER, QUALIFY, MERGE, and stream-side dedup compared on cost and semantics, plus how to pick the survivor row deterministically.
· 12 min
Cutting dbt run time and warehouse spend on a large project: find the real critical path, see when threads stop helping, and attribute cost per model.
· 12 min
An LLM call as a batch transformation step: content-hash idempotency, per-row cost budgets, retries for a non-deterministic API, and testing fuzzy output.
· 13 min
State transitions vs scheduler hours, execution history vs task logs, and the signals that tell you which orchestrator your pipeline has outgrown.
· 11 min
What decides whether a Spark stream survives a year in production: trigger choice, checkpoint discipline, watermark math, and what exactly-once guarantees.
· 12 min
How WITH RECURSIVE executes, patterns for hierarchy traversal and BOM explosion, and the cycle guards that keep a bad edge from running forever.
· 13 min
Lambda is excellent glue and a terrible framework. Here are the limits that shape every design, the idempotency you must build yourself, and the point to stop.
· 12 min
Where DuckDB belongs in a real pipeline, how far out-of-core execution gets you on one machine, and the concurrency and memory walls that decide when to stop.
· 13 min
Avro versus Protobuf, what each compatibility mode really allows, and the CI gate that stops a breaking schema change before it reaches a topic.
· 12 min
Which Jinja patterns earn their indirection in a production dbt project, how to test macros, and the metaprogramming that makes a project unmaintainable.
· 12 min
Conditional aggregation, native PIVOT syntax, unpivoting wide tables, and how to handle dynamic categories without generating SQL at runtime.
· 12 min
Native vector search in Snowflake, BigQuery, and pgvector is now good enough for most RAG workloads. Thresholds, real costs, and when a dedicated store wins.
· 13 min
Redshift Serverless vs Snowflake in production: how RPU-seconds differ from credits, where each bends under concurrency, and what breaks in a migration.
· 12 min
Split functional roles from access roles, use future grants and managed access schemas, and build a Snowflake permission model that stays reviewable.
· 11 min
How Spark executor memory is divided, why most OOMs are one oversized partition rather than a small cluster, and six failures you can read from the error.
· 13 min
What BigQuery reads before your data: partition metadata, Capacitor block statistics, and the query shapes that silently turn a pruned scan into a full one.
· 12 min
Choosing check or timestamp snapshot strategies, what happens when a snapshot run is missed, and when a hand-rolled SCD2 model beats dbt snapshot.
· 12 min
Idempotent producers, transactions, and read_committed give exactly-once inside Kafka. Write to a database and you still need an idempotent sink.
· 10 min
Pick a Snowflake warehouse size from evidence, not intuition, using spilling, queueing, and scaling tests to choose a bigger warehouse or more clusters.
· 10 min
One task at 40 minutes while 399 finished in 20 seconds is skew. Here is how I find the offending key, and the four fixes ranked by how much they cost me.
· 12 min
What happens to a CTE in Postgres, Snowflake, and BigQuery, when it blocks predicate pushdown, and when referencing it twice costs you two scans.
· 12 min
The failure modes that appear after launch (join paths, metric drift, runaway cost) and the semantic layer, constraints, and evals that make text-to-SQL work.
· 13 min
Athena bills for bytes scanned. The partition projection, Parquet layout, CTAS compaction, and workgroup guardrails I use to cut that number by 90 percent.
· 13 min
Taking a runaway BigQuery invoice apart: find the top jobs, fix pruning, cap bytes billed, use materialized views where they fit, and know when Editions wins.
· 11 min
How I lay out staging, intermediate, and marts so a dbt project still makes sense after two years: naming rules, ref boundaries, and folders that rot.
· 12 min
Rebalances are the most common cause of Kafka consumer lag spikes. The protocol, the four timeouts that matter, and the cooperative sticky config I ship.
· 12 min
A shuffle is a disk write, a network fetch, and a sort you did not ask for. What it costs, how to spot it in the Spark UI, and the rewrites that remove it.
· 12 min
How window frames actually evaluate, why RANGE and ROWS give different answers on ties, and six window patterns that delete self-joins from your models.
· 8 min
How Cortex Analyst semantic models and Cortex Search hybrid retrieval fit together, what the YAML actually controls, and where the accuracy comes from.
· 8 min
When Kinesis Data Streams earns its shards, when Firehose is enough, and the buffering and partitioning patterns that keep S3 landings queryable.
· 9 min
The join fan-out failure class: grain checks before and after every join, EXISTS for semi-joins, anti-joins done right, and the postmortem pattern.
· 8 min
How to get dbt CI from 50 minutes to 4 with state comparison and defer: manifest artifacts, GitHub Actions wiring, and the edge cases that bite.
· 8 min
How I structure Unity Catalog for real teams: three-level namespace design, group-based grants, lineage that works, and a hive_metastore migration that ships.
· 7 min
How the search access path works, what it costs to build and maintain, which predicates it serves, and when clustering keys are the better buy.
· 8 min
Clustering depth, what automatic reclustering costs, and a decision framework for clustering keys vs Search Optimization vs doing nothing.
· 8 min
Why raw text-to-SQL fails on real schemas, when retrieval over curated marts wins, and the semantic model and guardrails that make either safe.
· 9 min
Glue vs EMR for production Spark: DPU pricing vs instance pricing, cold starts, library control, and the job size where teams switch.
· 9 min
Five SQL habits that scan more than they should: SELECT *, functions on filter columns, DISTINCT as a bug fix, OR-joins, and per-row UDF calls.
· 8 min
How I structure dbt tests in production: generic tests on keys, unit tests on logic, dbt-expectations on shape, severity that means something.
· 9 min
How the _delta_log actually works: JSON commits, optimistic concurrency, checkpoints, deletion vectors, and the small-file problem nobody escapes.
· 8 min
How I read the operator tree: TableScan bytes, partition pruning, local and remote spilling, and the exchange steps that quietly dominate runtime.