fix: Avoid duplicate aggregators when reusing T-Digest sketches #20837
All Vouch review confidence checks passed
Residual risk 0.14 = Change Risk (0.35) × (1 − Review Confidence (0.60)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.35 · 177 lines diff across 2 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
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.310
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #20837"
general
weight: 0.35
FrankChen021
Fixes #20819
Description
Return a
FieldAccessPostAggregatorwhenTDIGEST_GENERATE_SKETCHreuses an existing sketch, so selectingTDIGEST_QUANTILEfirst no longer registers the same aggregator twiceAdd a SQL regression that checks the quantile and serialized sketch results and verifies that both outputs share one native sketch aggregator
Release note
Fixed SQL planning failures when
TDIGEST_GENERATE_SKETCHfollowsTDIGEST_QUANTILEwith the same input and compressionValidation
Tested with Temurin 25.0.5 and Maven 3.9.11
Duplicate field name: a0:aggand passes after the fixmvn -B -ntp test -pl extensions-contrib/tdigestsketch -Dsurefire.rerunFailingTestsCount=0 -Pskip-static-checks -Dweb.console.skip=true: 57 tests passed, no failures or skipsmvn -B -ntp verify -pl extensions-contrib/tdigestsketch -DskipTests -Dweb.console.skip=true -Dmaven.javadoc.skip=true -Dcyclonedx.skip=true: passed with static checks enabledmvn -B -ntp -pl extensions-contrib/tdigestsketch -Prat apache-rat:check dependency:analyze-only spotbugs:check -DoutputXML=true -DignoreNonCompile=true -DfailOnWarning=true: passedjavap -publicconfirms unchanged public signatures forTDigestGenerateSketchSqlAggregatorThis PR has: