← Back to Pull requests

test(delta): add embedded e2e ingestion test for Delta Lake input source #19611

Closed
unknown closed this pull request without merging on Jul 06, 2026 12:32 UTC
View on GitHub
unknown unknown commented on Jun 22, 2026 13:10 UTC
Author

Description

Adds an embedded end-to-end integration test for the Delta Lake input source, as suggested by @abhishekrb19 in https://github.com/apache/druid/pull/19592#issuecomment-4746247174.

It is modeled on the existing Iceberg embedded test (IcebergRestCatalogIngestionTest). Unlike Iceberg, Delta Lake reads directly from a local filesystem path, so no catalog or testcontainer is required — the test ingests a Delta table through a native IndexTask using DeltaInputSource and verifies the result over a real embedded Druid cluster (overlord, coordinator, indexer, broker, historical).

What it covers

The test reuses the regression table from #19592: 2 Parquet files × 2000 rows = 4000 rows total. Because each file exceeds the Delta kernel's default batch size of 1024 rows, this is the integration-level counterpart of the unit test DeltaInputSourceTest.BatchDrainRegressionTests for the per-file batch-drain bug (#18606):

  • Without the fix: 1024 × 2 = 2048 rows ingested

  • With the fix: 4000 rows ingested
  • Assertions:

  • COUNT(*) = 4000 (exact; the core regression signal)

  • MIN/MAX(__time) bounded by the id column's documented min/max (0 and 3999), confirming rows from both files were read
  • Depends on #19592

    This test exercises the fix in #19592 and is green only with that fix present. On master (which still has the bug) it asserts 4000 but the input source returns 2048, so CI here will be red until #19592 is merged. Kept as a draft for that reason. The change is otherwise self-contained (test + copied Delta table resource + a test-scoped druid-deltalake-extensions dependency).

    Key changed/added classes in this PR


  • DeltaLakeInputSourceIngestionTest (new embedded e2e test)

  • embedded-tests/pom.xml (test-scoped druid-deltalake-extensions dependency)

  • embedded-tests/src/test/resources/delta/large-row-group-table (Delta table fixture)
  • <hr>

    This PR has:

  • been self-reviewed.

  • added unit tests or modified existing tests to cover new code paths.
  • Diff: 257 lines (+192 / -65) across 3 files Reviewer: abhishekrb19 Review duration: 20121m
    All Vouch review confidence checks passed
    Residual risk 0.15 = Change Risk (0.39) × (1 − Review Confidence (0.60)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.39 · 257 lines diff across 3 files
    0.39
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.17 · 1 substantive comment(s)
    0.17
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    60%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.332
    Shallow Review Depth shallow_review_depth
    0.289
    Real PR Conversation Timeline
    1 comments
    "Review active on #19611"
    general weight: 0.35
    Reviewers
    Assignees
    Unassigned
    Labels
    risk: low confidence: 60.5% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 39.1% (MEDIUM) · Higher = larger blast radius
    39.1%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 60.5% · Lower = rushed or shallow review
    60.5%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 15.5% · Safe to merge
    15.5%
    Repository