CertMaster

🧱 ELT Pipelines & Medallion Architecture

Bronze/Silver/Gold, Auto Loader, Delta Live Tables

Databricks Data Engineer · DE-Associate · ⏱️ 25 min · ❓ 6 savol

🥉🥈🥇 Medallion Architecture

Bronze — raw data ingestion, hech narsa o'zgartirmasdan (append-only). Silver — tozalangan, validated, deduplicated data. Gold — business-level aggregations, reporting uchun tayyor. Har qatlam Delta format.

📥 Auto Loader

Cloud storage (S3/ADLS/GCS) dan yangi fayllarni avtomatik incremental ingestion. cloudFiles format. Schema inference va evolution. Checkpoint orqali exactly-once semantics. Millions of files — efficient.

🔄 Delta Live Tables (DLT)

Declarative pipeline framework. `@dlt.table` decorator. Live Tables (complete refresh) va Streaming Live Tables (incremental). Expectations — data quality constraints. Automated dependency management, error handling.

MERGE INTO (UPSERT)

Delta'da MERGE — upsert (update + insert). Source bilan target ni match qilib: mos kelsa update, mos kelmasa insert. SCD Type 1 (overwrite) va Type 2 (history) uchun ishlatiladi.
💡 Asosiy nuqtalar
📋 Kod misoli
-- Auto Loader (Bronze ingestion)
CREATE OR REFRESH STREAMING TABLE bronze_orders
AS SELECT
  current_timestamp() as ingestion_time,
  *
FROM cloud_files(
  "s3://bucket/orders/",
  "json",
  map("cloudFiles.inferColumnTypes", "true")
);

-- DLT Silver table (with expectations)
@dlt.table
@dlt.expect_or_drop("valid_amount", "amount > 0")
@dlt.expect_or_fail("not_null_id", "id IS NOT NULL")
def silver_orders():
  return (dlt.read_stream("bronze_orders")
    .dropDuplicates(["id"])
    .filter("status != 'CANCELLED'")
  )

-- MERGE INTO (upsert)
MERGE INTO silver_customers AS target
USING new_customers AS source
ON target.id = source.id
WHEN MATCHED THEN UPDATE SET *
WHEN NOT MATCHED THEN INSERT *;
🎯 Imtihon maslahatlari
⚠️ Ko'p adashadigan
🧠 Eslab qolish: "BSG Medals" = Bronze (raw silver Gold — medallar kabi, har biri oldingiidan toza). "MERGE = Match then Update or Insert"

ELT Pipelines & Medallion Architecture bo'yicha o'zingizni sinab ko'ring

Bepul interaktiv quiz, mock imtihon va to'liq darslar — CertMaster platformasida.

Bepul boshlash →