nguyetlt1012 opened a new issue, #13834:
URL: https://github.com/apache/hudi/issues/13834

   **_Tips before filing an issue_**
   
   - Have you gone through our [FAQs](https://hudi.apache.org/learn/faq/)?
   
   - Join the mailing list to engage in conversations and get faster support at 
[email protected].
   
   - If you have triaged this as a bug, then file an 
[issue](https://issues.apache.org/jira/projects/HUDI/issues) directly.
   
   **Describe the problem you faced**
   
   A clear and concise description of the problem.
   
   **To Reproduce**
   
   Steps to reproduce the behavior:
   
   1. I have a real-time ingestion pipeline using Spark Structured Streaming 
with metadata configuration for writing tables.
   ```
   "hoodie.table.type" -> "MERGE_ON_READ",
   "hoodie.datasource.write.table.type" -> "MERGE_ON_READ",
   "hoodie.datasource.write.operation" -> "upsert",
   "hoodie.datasource.write.recordkey.field" -> "record_key",
   "hoodie.datasource.write.partitionpath.field" -> "partition_date",
   "hoodie.datasource.write.precombine.field" -> "event_ts",
   "hoodie.datasource.write.hive_style_partitioning" -> "true",
   "hoodie.datasource.write.payload.class" -> 
"org.apache.hudi.common.model.PartialUpdateAvroPayload",
   "hoodie.compaction.logfile.size.threshold" -> "524288",
   "hoodie.log.file.max.size" -> "524288",
   "hoodie.datasource.compaction.async.enable" -> "true",
   ```
   2. Although I set compaction, when I check the timeline, I don't see any 
compaction commits. Then I manually run compaction using spark-submit.
   ```
   spark-submit \ 
   ...\
   --conf spark.sql.parquet.datetimeRebaseModeInWrite=CORRECTED \
   --conf spark.sql.parquet.int96RebaseModeInWrite=CORRECTED \
   --conf spark.sql.parquet.datetimeRebaseModeInRead=CORRECTED \
   --jars hudi-spark3.4-bundle_2.12-1.0.2.jar \
   --class org.apache.hudi.utilities.HoodieCompactor \
   hudi-utilities-bundle_2.12-1.0.2.jar \
   --base-path hdfs://xx \
   --table-name yy \
   --instant-time zz
   ```
   **Expected behavior**
   Run compaction successfully 
   
   **Environment Description**
   
   * Hudi version : 1.0.2
   
   * Spark version : 3.4.2
   
   * Hadoop version : 3.3.6
   
   * Storage (HDFS/S3/GCS..) : HDFS
   
   * Running on Docker? (yes/no) : no
   
   
   **Additional context**
   
   **Stacktrace**
   
   ```
   25/09/04 09:47:32 ERROR UtilHelpers: Compact failed
   org.apache.hudi.exception.HoodieCompactionException: COMPACT failed to write 
to 
files:443a1530-ec53-41c6-8599-3334250f1674-0,244939cc-f4d7-4d3c-8cbd-7519b7926bdf-0,c2a69856-b7b9-47fe-a88e-3562a690254a-0,22084d7c-799c-4883-b263-f3c69d6c8d8d-0,...
           at 
org.apache.hudi.client.BaseHoodieTableServiceClient.handleWriteErrors(BaseHoodieTableServiceClient.java:1207)
           at 
org.apache.hudi.client.BaseHoodieTableServiceClient.completeCompaction(BaseHoodieTableServiceClient.java:346)
           at 
org.apache.hudi.client.BaseHoodieTableServiceClient.compact(BaseHoodieTableServiceClient.java:323)
           at 
org.apache.hudi.client.BaseHoodieWriteClient.compact(BaseHoodieWriteClient.java:1175)
           at 
org.apache.hudi.client.BaseHoodieWriteClient.compact(BaseHoodieWriteClient.java:1095)
           at 
org.apache.hudi.utilities.HoodieCompactor.doCompact(HoodieCompactor.java:272)
           at 
org.apache.hudi.utilities.HoodieCompactor.lambda$compact$0(HoodieCompactor.java:210)
           at org.apache.hudi.utilities.UtilHelpers.retry(UtilHelpers.java:623)
           at 
org.apache.hudi.utilities.HoodieCompactor.compact(HoodieCompactor.java:193)
           at 
org.apache.hudi.utilities.HoodieCompactor.main(HoodieCompactor.java:179)
           at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
           at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
           at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
           at java.lang.reflect.Method.invoke(Method.java:498)
           at 
org.apache.spark.deploy.JavaMainApplication.start(SparkApplication.scala:52)
           at 
org.apache.spark.deploy.SparkSubmit.org$apache$spark$deploy$SparkSubmit$$runMain(SparkSubmit.scala:1020)
           at 
org.apache.spark.deploy.SparkSubmit.doRunMain$1(SparkSubmit.scala:192)
           at org.apache.spark.deploy.SparkSubmit.submit(SparkSubmit.scala:215)
           at org.apache.spark.deploy.SparkSubmit.doSubmit(SparkSubmit.scala:91)
           at 
org.apache.spark.deploy.SparkSubmit$$anon$2.doSubmit(SparkSubmit.scala:1111)
           at org.apache.spark.deploy.SparkSubmit$.main(SparkSubmit.scala:1120)
           at org.apache.spark.deploy.SparkSubmit.main(SparkSubmit.scala)
   Exception in thread "main" java.lang.RuntimeException: Failed in retry
           at org.apache.hudi.utilities.UtilHelpers.retry(UtilHelpers.java:627)
           at 
org.apache.hudi.utilities.HoodieCompactor.compact(HoodieCompactor.java:193)
           at 
org.apache.hudi.utilities.HoodieCompactor.main(HoodieCompactor.java:179)
           at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
           at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
           at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
           at java.lang.reflect.Method.invoke(Method.java:498)
           at 
org.apache.spark.deploy.JavaMainApplication.start(SparkApplication.scala:52)
           at 
org.apache.spark.deploy.SparkSubmit.org$apache$spark$deploy$SparkSubmit$$runMain(SparkSubmit.scala:1020)
           at 
org.apache.spark.deploy.SparkSubmit.doRunMain$1(SparkSubmit.scala:192)
           at org.apache.spark.deploy.SparkSubmit.submit(SparkSubmit.scala:215)
           at org.apache.spark.deploy.SparkSubmit.doSubmit(SparkSubmit.scala:91)
           at 
org.apache.spark.deploy.SparkSubmit$$anon$2.doSubmit(SparkSubmit.scala:1111)
           at org.apache.spark.deploy.SparkSubmit$.main(SparkSubmit.scala:1120)
           at org.apache.spark.deploy.SparkSubmit.main(SparkSubmit.scala)
   Caused by: org.apache.hudi.exception.HoodieCompactionException: COMPACT 
failed to write to 
files:443a1530-ec53-41c6-8599-3334250f1674-0,244939cc-f4d7-4d3c-8cbd-7519b7926bdf-0,...
           at 
org.apache.hudi.client.BaseHoodieTableServiceClient.handleWriteErrors(BaseHoodieTableServiceClient.java:1207)
           at 
org.apache.hudi.client.BaseHoodieTableServiceClient.completeCompaction(BaseHoodieTableServiceClient.java:346)
           at 
org.apache.hudi.client.BaseHoodieTableServiceClient.compact(BaseHoodieTableServiceClient.java:323)
           at 
org.apache.hudi.client.BaseHoodieWriteClient.compact(BaseHoodieWriteClient.java:1175)
           at 
org.apache.hudi.client.BaseHoodieWriteClient.compact(BaseHoodieWriteClient.java:1095)
           at 
org.apache.hudi.utilities.HoodieCompactor.doCompact(HoodieCompactor.java:272)
           at 
org.apache.hudi.utilities.HoodieCompactor.lambda$compact$0(HoodieCompactor.java:210)
           at org.apache.hudi.utilities.UtilHelpers.retry(UtilHelpers.java:623)
           ... 14 more
   ```
   
   


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to