← Back to Pull requests

[AURON #2360] Honor config alt keys when reading from SQLConf #2361

Closed
unknown closed this pull request without merging on Jun 30, 2026 01:16 UTC
View on GitHub
unknown unknown commented on Jun 25, 2026 17:01 UTC
Author

Which issue does this PR close?

Closes #2360

Rationale for this change

Config aliases declared via ConfigOption.addAltKey(...) were silently ignored: only the primary key was ever read from Spark's SQLConf, so every alternative key in SparkAuronConfiguration had no effect. For example, setting spark.auron.enable (the alt key of spark.auron.enabled) did not disable Auron.

The cause is in SparkAuronConfiguration.getFromSpark(...): alt keys were only resolved via ConfigEntry.findEntry(...) against Spark's global registry. Auron's options are not registered there, so the lookup always fell back to synthesizing a ConfigEntryWithDefaultFunction keyed on the primary key with an empty alternatives list, and ConfigEntry#readString therefore only read the primary key.

What changes are included in this PR?

  • Pass the (spark-prefixed) alt keys as the synthesized ConfigEntryWithDefaultFunction's alternatives so ConfigEntry#readString reads primaryKey +: alternatives, with the primary key taking precedence.

  • Add a unit test (AuronQuerySuite."config alt keys are honored") asserting both primary and alt keys take effect for AURON_ENABLED, and that the primary key wins when both are set.

  • Update the acosh null propagation test. With alt keys now honored, the test harness's spark.auron.enable=false baseline actually falls back to vanilla Spark, which exposed that vanilla Spark and the native engine can produce the same NaN with different bit patterns (checkSparkAnswerAndOperator/QueryTest compares doubles via Double.doubleToRawLongBits). The test now keeps the exact numeric/null comparison for in-domain inputs, and compares the out-of-domain (NaN-producing) inputs via the natively-supported isnan so no raw NaN bits are compared. The shared checkSparkAnswerAndOperator checker is left unchanged.

  • Disabled ansi mode for a failing test and created https://github.com/apache/auron/issues/2368
  • Are there any user-facing changes?

    Yes. Configuration alternative keys now work as documented. In particular, spark.auron.enable (alias of spark.auron.enabled) and spark.auron.ui.enable (alias of spark.auron.ui.enabled) now take effect. The primary key takes precedence when both are set.

    How was this patch tested?

  • Added AuronQuerySuite."config alt keys are honored".

  • Ran the full spark-extension-shims-spark test suite (Spark 3.5, Scala 2.12): 138 succeeded, 0 failed.
  • Diff: 310 lines (+232 / -78) across 3 files Reviewer: ShreyeshArangath Review duration: 6255m
    All Vouch review confidence checks passed
    Residual risk 0.25 = Change Risk (0.63) × (1 − Review Confidence (0.60)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.63 · 310 lines diff across 3 files
    0.63
    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.343
    Shallow Review Depth shallow_review_depth
    0.289
    Sensitive Paths sensitive_paths
    0.063
    Real PR Conversation Timeline
    1 comments
    "Review active on #2361"
    general weight: 0.35
    Assignees
    Unassigned
    Labels
    risk: low confidence: 60.5% reviewed sensitive_module
    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: 63.4% (MEDIUM) · Higher = larger blast radius
    63.4%
    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: 25.1% · Safe to merge
    25.1%
    Repository