You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hudi.apache.org by "SEPURI-SAI-KRISHNA (via GitHub)" <gi...@apache.org> on 2026/08/17 09:50:49 UTC

[PR] fix(spark): don't prune files with unknown null-count on IS NULL [hudi]

SEPURI-SAI-KRISHNA opened a new pull request, #19646:
URL: https://github.com/apache/hudi/pull/19646

   ### Describe the issue this Pull Request addresses
   
   Data skipping prunes files it must keep when a query filters on `IS NULL` (or `<=> null`)
   and the column-stats index holds no stats for that column in that file. Closes #19645.
   
   `DataSkippingUtils` translated:
   
   * `colA is null` → `colA_nullCount > 0`
   * `colA <=> null` → `colA_nullCount = null`
   
   The transposed column-stats index fills `min`/`max`/`nullCount` with `null` when a file has
   no stats record for a column — a column added by schema evolution (older files hold no
   record for it) or a column whose type the index does not support. For such rows the first
   predicate evaluates to `null` and the second is `null` for every row, so
   `indexDf.where(indexFilter)` drops them and the corresponding files are pruned. Records in
   those files are all null for that column, i.e. exactly the rows the query asks for, so the
   query silently returns fewer rows than it should.
   
   The `is not null` translation right below already handles the unknown-stats case
   (`colA_nullCount = null or colA_valueCount = null or ...`), and the fill-in code in
   `ColumnStatsIndexSupport#transpose` assumes "the filter includes an isNull check" — which
   held only for `is not null`.
   
   ### Summary and Changelog
   
   * `DataSkippingUtils`: `IsNull` and `EqualNullSafe(col, null)` now translate to
     `colA_nullCount is null OR colA_nullCount > 0`, via a new
     `ColumnStatsExpressionUtils#genColumnIsNullExpression` helper. A file whose null-count is
     unknown is kept instead of being pruned; when the null-count is known the pruning
     decision is unchanged.
   * `EqualNullSafe(col, null)` previously produced `colA_nullCount = null`, an always-null
     predicate that prunes every indexed file; it now shares the `IS NULL` translation, which
     is what `<=> null` means. (Spark's `NullPropagation` usually rewrites `col <=> null` into
     `col is null` before the filter reaches `HoodieFileIndex`, so this arm is mostly latent —
     but it is reached by callers that translate un-optimized expressions.)
   * Comments on both arms (and the mirrored ones in `containsNullOrValueCountBasedFilters`)
     now describe the actual translation.
   * `TestDataSkippingUtils`: three cases added to
     `testSupportedAndUnsupportedDataSkippingColumnsSource` (the suite that covers columns
     without stats) — `B is null`, `B <=> null` and `A = 1 and B is null` over an index where
     one file has no stats for `B`. All three fail on master and pass with this change.
   
   No code was copied.
   
   ### Impact
   
   Fixes silently incomplete results for `IS NULL` / `<=> null` queries on Spark when data
   skipping is enabled and the queried column has no stats in some files (most commonly after
   `ADD COLUMN` schema evolution). Files with unknown null-counts are now scanned, so such
   queries read a few more files than before — a correctness-required trade-off; queries on
   columns that are fully indexed are unaffected.
   
   No public API, config or storage-format change.
   
   ### Risk Level
   
   low
   
   The change only relaxes a pruning predicate (strictly fewer files are pruned), so it cannot
   introduce new false pruning. Verified with the new and existing `TestDataSkippingUtils`
   cases.
   
   ### Documentation Update
   
   none
   
   ### Contributor's checklist
   
   - [x] Read through [contributor's guide](https://hudi.apache.org/contribute/how-to-contribute)
   - [x] Enough context is provided in the sections above
   - [x] Adequate tests were added if applicable
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(spark): don't prune files with unknown null-count on IS NULL [hudi]

Posted by "hudi-bot (via GitHub)" <gi...@apache.org>.
hudi-bot commented on PR #19646:
URL: https://github.com/apache/hudi/pull/19646#issuecomment-5351124819

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336",
       "triggerID" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "triggerType" : "PUSH"
     }, {
       "hash" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336",
       "triggerID" : "5315349030",
       "triggerType" : "MANUAL"
     }, {
       "hash" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336",
       "triggerID" : "5340529144",
       "triggerType" : "MANUAL"
     }, {
       "hash" : "7d7688f2eb4b84ecfbffb6f2118b8fdf89442f6a",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "7d7688f2eb4b84ecfbffb6f2118b8fdf89442f6a",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1 Azure: [FAILURE](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336) 
   * 7d7688f2eb4b84ecfbffb6f2118b8fdf89442f6a UNKNOWN
   
   <details>
   <summary>Bot commands</summary>
     @hudi-bot supports the following commands:
   
    - `@hudi-bot run azure` re-run the last Azure build
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(spark): don't prune files with unknown null-count on IS NULL [hudi]

Posted by "hudi-agent (via GitHub)" <gi...@apache.org>.
hudi-agent commented on code in PR #19646:
URL: https://github.com/apache/hudi/pull/19646#discussion_r3818468453


##########
hudi-spark-datasource/hudi-spark-common/src/main/scala/org/apache/spark/sql/hudi/DataSkippingUtils.scala:
##########
@@ -479,6 +482,16 @@ object ColumnStatsExpressionUtils {
   @inline def genColNumNullsExpr(colName: String): Expression = sparkAdapter.getExpressionFromColumn(col(getNullCountColumnNameFor(colName)))
   @inline def genColValueCountExpr: Expression = sparkAdapter.getExpressionFromColumn(col(getValueCountColumnNameFor))
 
+  @inline def genColumnIsNullExpression(colName: String): Expression = {

Review Comment:
   🤖 nit: the sibling helpers in this object use the `Expr` suffix (`genColNumNullsExpr`, `genColValueCountExpr`) — could you rename this to `genColumnIsNullExpr` for consistency?
   
   <sub><i>⚠️ AI-generated; verify before applying. React 👍/👎 to flag quality.</i></sub>



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(spark): don't prune files with unknown null-count on IS NULL [hudi]

Posted by "hudi-bot (via GitHub)" <gi...@apache.org>.
hudi-bot commented on PR #19646:
URL: https://github.com/apache/hudi/pull/19646#issuecomment-5351157842

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336",
       "triggerID" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "triggerType" : "PUSH"
     }, {
       "hash" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336",
       "triggerID" : "5315349030",
       "triggerType" : "MANUAL"
     }, {
       "hash" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336",
       "triggerID" : "5340529144",
       "triggerType" : "MANUAL"
     }, {
       "hash" : "7d7688f2eb4b84ecfbffb6f2118b8fdf89442f6a",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16400",
       "triggerID" : "7d7688f2eb4b84ecfbffb6f2118b8fdf89442f6a",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1 Azure: [FAILURE](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336) 
   * 7d7688f2eb4b84ecfbffb6f2118b8fdf89442f6a Azure: [PENDING](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16400) 
   
   <details>
   <summary>Bot commands</summary>
     @hudi-bot supports the following commands:
   
    - `@hudi-bot run azure` re-run the last Azure build
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(spark): don't prune files with unknown null-count on IS NULL [hudi]

Posted by "danny0405 (via GitHub)" <gi...@apache.org>.
danny0405 commented on code in PR #19646:
URL: https://github.com/apache/hudi/pull/19646#discussion_r3800448297


##########
hudi-spark-datasource/hudi-spark-common/src/main/scala/org/apache/spark/sql/hudi/DataSkippingUtils.scala:
##########
@@ -160,11 +160,12 @@ object DataSkippingUtils extends Logging {
           Option.empty
         })
 
-      // Filter "colA = null"
-      // Translates to "colA_nullCount = null" for index lookup
-      case EqualNullSafe(attrRef: AttributeReference, litNull @ Literal(null, _)) =>
+      // Filter "colA <=> null"
+      // Translates to "colA_nullCount = null or colA_nullCount > 0" for index lookup
+      // (this is equivalent to "colA is null")
+      case EqualNullSafe(attrRef: AttributeReference, Literal(null, _)) =>
         getTargetIndexedColumnName(attrRef, indexedCols)
-          .map(colName => EqualTo(genColNumNullsExpr(colName), litNull))
+          .map(colName => genColumnIsNullExpression(colName))

Review Comment:
   nice catch



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(spark): don't prune files with unknown null-count on IS NULL [hudi]

Posted by "SEPURI-SAI-KRISHNA (via GitHub)" <gi...@apache.org>.
SEPURI-SAI-KRISHNA commented on code in PR #19646:
URL: https://github.com/apache/hudi/pull/19646#discussion_r3818414252


##########
hudi-spark-datasource/hudi-spark-common/src/main/scala/org/apache/spark/sql/hudi/DataSkippingUtils.scala:
##########
@@ -160,11 +160,12 @@ object DataSkippingUtils extends Logging {
           Option.empty
         })
 
-      // Filter "colA = null"
-      // Translates to "colA_nullCount = null" for index lookup
-      case EqualNullSafe(attrRef: AttributeReference, litNull @ Literal(null, _)) =>
+      // Filter "colA <=> null"
+      // Translates to "colA_nullCount = null or colA_nullCount > 0" for index lookup

Review Comment:
   Good point — `= NULL` is exactly the thing this patch is fixing, so spelling it that way in the comment is confusing. Updated all five comments this PR touched to `colA_nullCount IS NULL OR colA_nullCount > 0`.
   
   I also went one line further and gave the neighbouring `is not null` comments the same treatment (`colA_nullCount IS NULL OR colA_valueCount IS NULL OR ...`), since they describe the `Or(Or(IsNull(numNullExpr), IsNull(valueCountExpr)), ...)` that arm builds and had the same `= null` wording. Happy to drop that hunk if you'd rather keep the diff to the lines this PR already changed.
   
   Comment-only change, no behavior difference.
   



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(spark): don't prune files with unknown null-count on IS NULL [hudi]

Posted by "hudi-bot (via GitHub)" <gi...@apache.org>.
hudi-bot commented on PR #19646:
URL: https://github.com/apache/hudi/pull/19646#issuecomment-5315351440

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336",
       "triggerID" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "triggerType" : "PUSH"
     }, {
       "hash" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "5315349030",
       "triggerType" : "MANUAL"
     } ]
   }-->
   ## CI report:
   
   * c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1 Azure: [FAILURE](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336) 
   
   <details>
   <summary>Bot commands</summary>
     @hudi-bot supports the following commands:
   
    - `@hudi-bot run azure` re-run the last Azure build
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(spark): don't prune files with unknown null-count on IS NULL [hudi]

Posted by "danny0405 (via GitHub)" <gi...@apache.org>.
danny0405 merged PR #19646:
URL: https://github.com/apache/hudi/pull/19646


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(spark): don't prune files with unknown null-count on IS NULL [hudi]

Posted by "hudi-bot (via GitHub)" <gi...@apache.org>.
hudi-bot commented on PR #19646:
URL: https://github.com/apache/hudi/pull/19646#issuecomment-5340553220

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336",
       "triggerID" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "triggerType" : "PUSH"
     }, {
       "hash" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336",
       "triggerID" : "5315349030",
       "triggerType" : "MANUAL"
     }, {
       "hash" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "5340529144",
       "triggerType" : "MANUAL"
     } ]
   }-->
   ## CI report:
   
   * c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1 Azure: [FAILURE](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336) 
   
   <details>
   <summary>Bot commands</summary>
     @hudi-bot supports the following commands:
   
    - `@hudi-bot run azure` re-run the last Azure build
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(spark): don't prune files with unknown null-count on IS NULL [hudi]

Posted by "SEPURI-SAI-KRISHNA (via GitHub)" <gi...@apache.org>.
SEPURI-SAI-KRISHNA commented on code in PR #19646:
URL: https://github.com/apache/hudi/pull/19646#discussion_r3820558141


##########
hudi-spark-datasource/hudi-spark-common/src/main/scala/org/apache/spark/sql/hudi/DataSkippingUtils.scala:
##########
@@ -479,6 +482,16 @@ object ColumnStatsExpressionUtils {
   @inline def genColNumNullsExpr(colName: String): Expression = sparkAdapter.getExpressionFromColumn(col(getNullCountColumnNameFor(colName)))
   @inline def genColValueCountExpr: Expression = sparkAdapter.getExpressionFromColumn(col(getValueCountColumnNameFor))
 
+  @inline def genColumnIsNullExpression(colName: String): Expression = {

Review Comment:
   The convention in this object is split by what the helper does, rather than uniform, so I'd like to keep the current name:
   
   * `genCol…Expr` — `genColMinValueExpr`, `genColMaxValueExpr`, `genColNumNullsExpr`, `genColValueCountExpr`. These fetch a single column-stats column.
   * `genColumn…Expression` — `genColumnValuesEqualToExpression`, `genColumnOnlyValuesEqualToExpression`. These compose a whole predicate out of the accessors above.
   
   `genColumnIsNullExpression` is in the second group: it builds `Or(IsNull(numNullsExpr), GreaterThan(numNullsExpr, Literal(0)))` on top of `genColNumNullsExpr`, exactly as `genColumnValuesEqualToExpression` does. Renaming it to `genColumnIsNullExpr` would pair the `genColumn` prefix with the `Expr` suffix and match neither group.
   
   Happy to rename if a committer prefers otherwise.
   



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(spark): don't prune files with unknown null-count on IS NULL [hudi]

Posted by "hudi-bot (via GitHub)" <gi...@apache.org>.
hudi-bot commented on PR #19646:
URL: https://github.com/apache/hudi/pull/19646#issuecomment-5314748995

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336",
       "triggerID" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1 Azure: [PENDING](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336) 
   
   <details>
   <summary>Bot commands</summary>
     @hudi-bot supports the following commands:
   
    - `@hudi-bot run azure` re-run the last Azure build
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(spark): don't prune files with unknown null-count on IS NULL [hudi]

Posted by "hudi-bot (via GitHub)" <gi...@apache.org>.
hudi-bot commented on PR #19646:
URL: https://github.com/apache/hudi/pull/19646#issuecomment-5351495643

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336",
       "triggerID" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "triggerType" : "PUSH"
     }, {
       "hash" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336",
       "triggerID" : "5315349030",
       "triggerType" : "MANUAL"
     }, {
       "hash" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336",
       "triggerID" : "5340529144",
       "triggerType" : "MANUAL"
     }, {
       "hash" : "7d7688f2eb4b84ecfbffb6f2118b8fdf89442f6a",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16400",
       "triggerID" : "7d7688f2eb4b84ecfbffb6f2118b8fdf89442f6a",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 7d7688f2eb4b84ecfbffb6f2118b8fdf89442f6a Azure: [FAILURE](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16400) 
   
   <details>
   <summary>Bot commands</summary>
     @hudi-bot supports the following commands:
   
    - `@hudi-bot run azure` re-run the last Azure build
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(spark): don't prune files with unknown null-count on IS NULL [hudi]

Posted by "hudi-bot (via GitHub)" <gi...@apache.org>.
hudi-bot commented on PR #19646:
URL: https://github.com/apache/hudi/pull/19646#issuecomment-5315409053

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336",
       "triggerID" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "triggerType" : "PUSH"
     }, {
       "hash" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336",
       "triggerID" : "5315349030",
       "triggerType" : "MANUAL"
     } ]
   }-->
   ## CI report:
   
   * c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1 Azure: [FAILURE](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336) 
   
   <details>
   <summary>Bot commands</summary>
     @hudi-bot supports the following commands:
   
    - `@hudi-bot run azure` re-run the last Azure build
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(spark): don't prune files with unknown null-count on IS NULL [hudi]

Posted by "codecov-commenter (via GitHub)" <gi...@apache.org>.
codecov-commenter commented on PR #19646:
URL: https://github.com/apache/hudi/pull/19646#issuecomment-5342922793

   ## [Codecov](https://app.codecov.io/gh/apache/hudi/pull/19646?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) Report
   :white_check_mark: All modified and coverable lines are covered by tests.
   :white_check_mark: Project coverage is 75.91%. Comparing base ([`b6c4677`](https://app.codecov.io/gh/apache/hudi/commit/b6c4677206b4ba241c4b9b85110da60fcec7e1f3?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)) to head ([`c47d460`](https://app.codecov.io/gh/apache/hudi/commit/c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)).
   :warning: Report is 11 commits behind head on master.
   
   <details><summary>Additional details and impacted files</summary>
   
   
   
   ```diff
   @@            Coverage Diff            @@
   ##             master   #19646   +/-   ##
   =========================================
     Coverage     75.91%   75.91%           
     Complexity    32313    32313           
   =========================================
     Files          2524     2524           
     Lines        139550   139547    -3     
     Branches      16793    16792    -1     
   =========================================
   - Hits         105943   105942    -1     
   + Misses        26095    26094    -1     
   + Partials       7512     7511    -1     
   ```
   
   | [Components](https://app.codecov.io/gh/apache/hudi/pull/19646/components?src=pr&el=components&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Coverage Δ | |
   |---|---|---|
   | [hudi-common](https://app.codecov.io/gh/apache/hudi/pull/19646/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `83.10% <ø> (ø)` | |
   | [hudi-client](https://app.codecov.io/gh/apache/hudi/pull/19646/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `82.47% <ø> (ø)` | |
   | [hudi-flink](https://app.codecov.io/gh/apache/hudi/pull/19646/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `85.74% <ø> (ø)` | |
   | [hudi-spark-datasource](https://app.codecov.io/gh/apache/hudi/pull/19646/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `71.59% <ø> (+<0.01%)` | :arrow_up: |
   | [hudi-utilities](https://app.codecov.io/gh/apache/hudi/pull/19646/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `53.99% <ø> (ø)` | |
   | [hudi-cli](https://app.codecov.io/gh/apache/hudi/pull/19646/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `15.26% <ø> (ø)` | |
   | [hudi-hadoop](https://app.codecov.io/gh/apache/hudi/pull/19646/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `69.02% <ø> (ø)` | |
   | [hudi-sync](https://app.codecov.io/gh/apache/hudi/pull/19646/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `75.58% <ø> (ø)` | |
   | [hudi-io](https://app.codecov.io/gh/apache/hudi/pull/19646/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `78.94% <ø> (ø)` | |
   | [hudi-timeline-service](https://app.codecov.io/gh/apache/hudi/pull/19646/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `83.44% <ø> (ø)` | |
   | [hudi-cloud](https://app.codecov.io/gh/apache/hudi/pull/19646/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `64.06% <ø> (ø)` | |
   | [hudi-kafka-connect](https://app.codecov.io/gh/apache/hudi/pull/19646/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `53.20% <ø> (ø)` | |
   
   | [Flag](https://app.codecov.io/gh/apache/hudi/pull/19646/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Coverage Δ | |
   |---|---|---|
   | [hadoop-mr-java-client](https://app.codecov.io/gh/apache/hudi/pull/19646/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `43.83% <ø> (+<0.01%)` | :arrow_up: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Files with missing lines](https://app.codecov.io/gh/apache/hudi/pull/19646?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Coverage Δ | |
   |---|---|---|
   | [.../org/apache/spark/sql/hudi/DataSkippingUtils.scala](https://app.codecov.io/gh/apache/hudi/pull/19646?src=pr&el=tree&filepath=hudi-spark-datasource%2Fhudi-spark-common%2Fsrc%2Fmain%2Fscala%2Forg%2Fapache%2Fspark%2Fsql%2Fhudi%2FDataSkippingUtils.scala&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-aHVkaS1zcGFyay1kYXRhc291cmNlL2h1ZGktc3BhcmstY29tbW9uL3NyYy9tYWluL3NjYWxhL29yZy9hcGFjaGUvc3Bhcmsvc3FsL2h1ZGkvRGF0YVNraXBwaW5nVXRpbHMuc2NhbGE=) | `78.63% <ø> (+0.60%)` | :arrow_up: |
   </details>
   <details><summary> :rocket: New features to boost your workflow: </summary>
   
   - :snowflake: [Test Analytics](https://docs.codecov.com/docs/test-analytics): Detect flaky tests, report on failures, and find test suite problems.
   - :package: [JS Bundle Analysis](https://docs.codecov.com/docs/javascript-bundle-analysis): Save yourself from yourself by tracking and limiting bundle sizes in JS merges.
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(spark): don't prune files with unknown null-count on IS NULL [hudi]

Posted by "SEPURI-SAI-KRISHNA (via GitHub)" <gi...@apache.org>.
SEPURI-SAI-KRISHNA commented on PR #19646:
URL: https://github.com/apache/hudi/pull/19646#issuecomment-5315349030

   @hudi-bot run azure


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(spark): don't prune files with unknown null-count on IS NULL [hudi]

Posted by "voonhous (via GitHub)" <gi...@apache.org>.
voonhous commented on PR #19646:
URL: https://github.com/apache/hudi/pull/19646#issuecomment-5340440558

   We will need this in `release-1.2.1`. @danny0405 Please shepherd this, thank you.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(spark): don't prune files with unknown null-count on IS NULL [hudi]

Posted by "hudi-bot (via GitHub)" <gi...@apache.org>.
hudi-bot commented on PR #19646:
URL: https://github.com/apache/hudi/pull/19646#issuecomment-5340610485

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336",
       "triggerID" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "triggerType" : "PUSH"
     }, {
       "hash" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336",
       "triggerID" : "5315349030",
       "triggerType" : "MANUAL"
     }, {
       "hash" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336",
       "triggerID" : "5340529144",
       "triggerType" : "MANUAL"
     } ]
   }-->
   ## CI report:
   
   * c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1 Azure: [FAILURE](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336) 
   
   <details>
   <summary>Bot commands</summary>
     @hudi-bot supports the following commands:
   
    - `@hudi-bot run azure` re-run the last Azure build
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(spark): don't prune files with unknown null-count on IS NULL [hudi]

Posted by "hudi-bot (via GitHub)" <gi...@apache.org>.
hudi-bot commented on PR #19646:
URL: https://github.com/apache/hudi/pull/19646#issuecomment-5315296464

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336",
       "triggerID" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1 Azure: [FAILURE](https://dev.azure.com/apachehudi/a1a51da7-8592-47d4-88dc-fd67bed336bb/_build/results?buildId=16336) 
   
   <details>
   <summary>Bot commands</summary>
     @hudi-bot supports the following commands:
   
    - `@hudi-bot run azure` re-run the last Azure build
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(spark): don't prune files with unknown null-count on IS NULL [hudi]

Posted by "SEPURI-SAI-KRISHNA (via GitHub)" <gi...@apache.org>.
SEPURI-SAI-KRISHNA commented on PR #19646:
URL: https://github.com/apache/hudi/pull/19646#issuecomment-5316095408

   CI triage: build 16336 had two failures, both unrelated to this change. `UT FT common & other modules` lost its Azure agent, and 
     `TestValidateHoodieSyncProcedure` failed with `NoClassDefFoundError` under `Free memory is lower than 5%` — the same test also fails on #19648, an unrelated PR. Neither phase 
     exercises `DataSkippingUtils`. Happy to rebase if useful.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(spark): don't prune files with unknown null-count on IS NULL [hudi]

Posted by "hudi-bot (via GitHub)" <gi...@apache.org>.
hudi-bot commented on PR #19646:
URL: https://github.com/apache/hudi/pull/19646#issuecomment-5314590227

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * c47d46028dc90d5ab2b2a7500e03df0f4fe6dab1 UNKNOWN
   
   <details>
   <summary>Bot commands</summary>
     @hudi-bot supports the following commands:
   
    - `@hudi-bot run azure` re-run the last Azure build
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(spark): don't prune files with unknown null-count on IS NULL [hudi]

Posted by "SEPURI-SAI-KRISHNA (via GitHub)" <gi...@apache.org>.
SEPURI-SAI-KRISHNA commented on PR #19646:
URL: https://github.com/apache/hudi/pull/19646#issuecomment-5340529144

   @hudi-bot run azure


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(spark): don't prune files with unknown null-count on IS NULL [hudi]

Posted by "danny0405 (via GitHub)" <gi...@apache.org>.
danny0405 commented on code in PR #19646:
URL: https://github.com/apache/hudi/pull/19646#discussion_r3818012386


##########
hudi-spark-datasource/hudi-spark-common/src/main/scala/org/apache/spark/sql/hudi/DataSkippingUtils.scala:
##########
@@ -160,11 +160,12 @@ object DataSkippingUtils extends Logging {
           Option.empty
         })
 
-      // Filter "colA = null"
-      // Translates to "colA_nullCount = null" for index lookup
-      case EqualNullSafe(attrRef: AttributeReference, litNull @ Literal(null, _)) =>
+      // Filter "colA <=> null"
+      // Translates to "colA_nullCount = null or colA_nullCount > 0" for index lookup

Review Comment:
   Could we spell this as `colA_nullCount IS NULL OR colA_nullCount > 0` (and likewise in the other updated comments)? In SQL, `= NULL` evaluates to unknown—the exact behavior this patch is correcting—while the generated expression now uses `IsNull`. Using `IS NULL` here would keep the comment aligned with the implementation.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org