You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hudi.apache.org by "boneanxs (via GitHub)" <gi...@apache.org> on 2023/11/09 02:07:29 UTC

[PR] [HUDI-7054][FOLLOW_UP] HoodieCatalogTable should ignore lazily deleted partitions [hudi]

boneanxs opened a new pull request, #10024:
URL: https://github.com/apache/hudi/pull/10024

   ### Change Logs
   
   _Describe context and summary for this change. Highlight if any code was copied._
   Thinking it might be better to directly let `HoodieCatalogTable` to filter deleted partitions, it shouldn't show deleted partitions when calling `getPartitionPaths`.
   
   This can also fix `RepairHoodieTableCommand` to not repair deleted partitions.
   
   ### Impact
   
   _Describe any public API or user-facing feature change or any performance impact._
   None
   
   ### Risk level (write none, low medium or high below)
   
   _If medium or high, explain what verification was done to mitigate the risks._
   None
   ### Documentation Update
   
   _Describe any necessary documentation update if there is any new feature, config, or user-facing change_
   
   - _The config description must be updated if new configs are added or the default value of the configs are changed_
   - _Any new feature or user-facing change requires updating the Hudi website. Please create a Jira ticket, attach the
     ticket number here and follow the [instruction](https://hudi.apache.org/contribute/developer-setup#website) to make
     changes to the website._
   
   ### Contributor's checklist
   
   - [ ] Read through [contributor's guide](https://hudi.apache.org/contribute/how-to-contribute)
   - [ ] Change Logs and Impact were stated clearly
   - [ ] Adequate tests were added if applicable
   - [ ] CI passed
   


-- 
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] [HUDI-7054][FOLLOW_UP] HoodieCatalogTable should ignore lazily deleted partitions [hudi]

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

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "17566af6a57a43de3b2a5d5ab7bcd8bd28336307",
       "status" : "SUCCESS",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=20752",
       "triggerID" : "17566af6a57a43de3b2a5d5ab7bcd8bd28336307",
       "triggerType" : "PUSH"
     }, {
       "hash" : "7c0ff25207cc19c5496dc4e7e688c3a8527663d2",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=20766",
       "triggerID" : "7c0ff25207cc19c5496dc4e7e688c3a8527663d2",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 17566af6a57a43de3b2a5d5ab7bcd8bd28336307 Azure: [SUCCESS](https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=20752) 
   * 7c0ff25207cc19c5496dc4e7e688c3a8527663d2 Azure: [PENDING](https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=20766) 
   
   <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] [HUDI-7054][FOLLOW_UP] HoodieCatalogTable should ignore lazily deleted partitions [hudi]

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

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "17566af6a57a43de3b2a5d5ab7bcd8bd28336307",
       "status" : "SUCCESS",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=20752",
       "triggerID" : "17566af6a57a43de3b2a5d5ab7bcd8bd28336307",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 17566af6a57a43de3b2a5d5ab7bcd8bd28336307 Azure: [SUCCESS](https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=20752) 
   
   <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] [HUDI-7054][FOLLOW_UP] HoodieCatalogTable should ignore lazily deleted partitions [hudi]

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


-- 
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] [HUDI-7054][FOLLOW_UP] HoodieCatalogTable should ignore lazily deleted partitions [hudi]

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


##########
hudi-spark-datasource/hudi-spark-common/src/main/scala/org/apache/spark/sql/catalyst/catalog/HoodieCatalogTable.scala:
##########
@@ -169,9 +170,10 @@ class HoodieCatalogTable(val spark: SparkSession, var table: CatalogTable) exten
   lazy val partitionSchema: StructType = StructType(tableSchema.filter(f => partitionFields.contains(f.name)))
 
   /**
-   * All the partition paths
+   * All the partition paths, excludes lazily deleted partitions.
    */
   def getPartitionPaths: Seq[String] = getAllPartitionPaths(spark, table)
+    .filter(!TimelineUtils.getDroppedPartitions(metaClient.getActiveTimeline).contains(_))
 

Review Comment:
   Oh! make senses, thanks for point this, let me fix it.



-- 
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] [HUDI-7054][FOLLOW_UP] HoodieCatalogTable should ignore lazily deleted partitions [hudi]

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

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "17566af6a57a43de3b2a5d5ab7bcd8bd28336307",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=20752",
       "triggerID" : "17566af6a57a43de3b2a5d5ab7bcd8bd28336307",
       "triggerType" : "PUSH"
     }, {
       "hash" : "7c0ff25207cc19c5496dc4e7e688c3a8527663d2",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=20766",
       "triggerID" : "7c0ff25207cc19c5496dc4e7e688c3a8527663d2",
       "triggerType" : "PUSH"
     }, {
       "hash" : "7c0ff25207cc19c5496dc4e7e688c3a8527663d2",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=20766",
       "triggerID" : "1803689997",
       "triggerType" : "MANUAL"
     } ]
   }-->
   ## CI report:
   
   * 7c0ff25207cc19c5496dc4e7e688c3a8527663d2 Azure: [FAILURE](https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=20766) 
   
   <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] [HUDI-7054][FOLLOW_UP] HoodieCatalogTable should ignore lazily deleted partitions [hudi]

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

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "17566af6a57a43de3b2a5d5ab7bcd8bd28336307",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "17566af6a57a43de3b2a5d5ab7bcd8bd28336307",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 17566af6a57a43de3b2a5d5ab7bcd8bd28336307 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] [HUDI-7054][FOLLOW_UP] HoodieCatalogTable should ignore lazily deleted partitions [hudi]

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

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "17566af6a57a43de3b2a5d5ab7bcd8bd28336307",
       "status" : "SUCCESS",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=20752",
       "triggerID" : "17566af6a57a43de3b2a5d5ab7bcd8bd28336307",
       "triggerType" : "PUSH"
     }, {
       "hash" : "7c0ff25207cc19c5496dc4e7e688c3a8527663d2",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "7c0ff25207cc19c5496dc4e7e688c3a8527663d2",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 17566af6a57a43de3b2a5d5ab7bcd8bd28336307 Azure: [SUCCESS](https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=20752) 
   * 7c0ff25207cc19c5496dc4e7e688c3a8527663d2 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] [HUDI-7054][FOLLOW_UP] HoodieCatalogTable should ignore lazily deleted partitions [hudi]

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

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "17566af6a57a43de3b2a5d5ab7bcd8bd28336307",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=20752",
       "triggerID" : "17566af6a57a43de3b2a5d5ab7bcd8bd28336307",
       "triggerType" : "PUSH"
     }, {
       "hash" : "7c0ff25207cc19c5496dc4e7e688c3a8527663d2",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=20766",
       "triggerID" : "7c0ff25207cc19c5496dc4e7e688c3a8527663d2",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 7c0ff25207cc19c5496dc4e7e688c3a8527663d2 Azure: [FAILURE](https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=20766) 
   
   <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] [HUDI-7054][FOLLOW_UP] HoodieCatalogTable should ignore lazily deleted partitions [hudi]

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

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "17566af6a57a43de3b2a5d5ab7bcd8bd28336307",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=20752",
       "triggerID" : "17566af6a57a43de3b2a5d5ab7bcd8bd28336307",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 17566af6a57a43de3b2a5d5ab7bcd8bd28336307 Azure: [PENDING](https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=20752) 
   
   <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] [HUDI-7054][FOLLOW_UP] HoodieCatalogTable should ignore lazily deleted partitions [hudi]

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

   @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] [HUDI-7054][FOLLOW_UP] HoodieCatalogTable should ignore lazily deleted partitions [hudi]

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

   ![Screenshot 2023-11-10 at 14 10 44](https://github.com/apache/hudi/assets/10115332/0ccd00c6-a4a6-4d7e-9db7-57629ee5a20e)
   The CI actually passes, @danny0405 


-- 
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] [HUDI-7054][FOLLOW_UP] HoodieCatalogTable should ignore lazily deleted partitions [hudi]

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


##########
hudi-spark-datasource/hudi-spark-common/src/main/scala/org/apache/spark/sql/catalyst/catalog/HoodieCatalogTable.scala:
##########
@@ -169,9 +170,10 @@ class HoodieCatalogTable(val spark: SparkSession, var table: CatalogTable) exten
   lazy val partitionSchema: StructType = StructType(tableSchema.filter(f => partitionFields.contains(f.name)))
 
   /**
-   * All the partition paths
+   * All the partition paths, excludes lazily deleted partitions.
    */
   def getPartitionPaths: Seq[String] = getAllPartitionPaths(spark, table)
+    .filter(!TimelineUtils.getDroppedPartitions(metaClient.getActiveTimeline).contains(_))
 

Review Comment:
   Will this trigger the calculation for each partition ?



-- 
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] [HUDI-7054][FOLLOW_UP] HoodieCatalogTable should ignore lazily deleted partitions [hudi]

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

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "17566af6a57a43de3b2a5d5ab7bcd8bd28336307",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=20752",
       "triggerID" : "17566af6a57a43de3b2a5d5ab7bcd8bd28336307",
       "triggerType" : "PUSH"
     }, {
       "hash" : "7c0ff25207cc19c5496dc4e7e688c3a8527663d2",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=20766",
       "triggerID" : "7c0ff25207cc19c5496dc4e7e688c3a8527663d2",
       "triggerType" : "PUSH"
     }, {
       "hash" : "7c0ff25207cc19c5496dc4e7e688c3a8527663d2",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "1803689997",
       "triggerType" : "MANUAL"
     } ]
   }-->
   ## CI report:
   
   * 7c0ff25207cc19c5496dc4e7e688c3a8527663d2 Azure: [FAILURE](https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=20766) 
   
   <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