You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hudi.apache.org by GitBox <gi...@apache.org> on 2022/10/21 11:53:58 UTC

[GitHub] [hudi] xicm opened a new pull request, #7020: [HUDI-5069] TestInlineCompaction.testSuccessfulCompactionBasedOnNumAndTime is flaky

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

   ### Change Logs
   
   fix flaky test testSuccessfulCompactionBasedOnNumAndTime
   
   ### Impact
   
   _Describe any public API or user-facing feature change or any performance impact._
   
   ### Risk level (write none, low medium or high below)
   low
   
   _If medium or high, explain what verification was done to mitigate the risks._
   
   ### 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


[GitHub] [hudi] hudi-bot commented on pull request #7020: [HUDI-5069] TestInlineCompaction.testSuccessfulCompactionBasedOnNumAndTime is flaky

Posted by GitBox <gi...@apache.org>.
hudi-bot commented on PR #7020:
URL: https://github.com/apache/hudi/pull/7020#issuecomment-1288094091

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


[GitHub] [hudi] hudi-bot commented on pull request #7020: [HUDI-5069] TestInlineCompaction.testSuccessfulCompactionBasedOnNumAndTime is flaky

Posted by GitBox <gi...@apache.org>.
hudi-bot commented on PR #7020:
URL: https://github.com/apache/hudi/pull/7020#issuecomment-1288045597

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "c1f5e56dcb463d42ee57af37502846ce68528628",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=12425",
       "triggerID" : "c1f5e56dcb463d42ee57af37502846ce68528628",
       "triggerType" : "PUSH"
     }, {
       "hash" : "04d5ca0a11f5f8568f2d389dc4ec60468c04b596",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=12488",
       "triggerID" : "04d5ca0a11f5f8568f2d389dc4ec60468c04b596",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * c1f5e56dcb463d42ee57af37502846ce68528628 Azure: [FAILURE](https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=12425) 
   * 04d5ca0a11f5f8568f2d389dc4ec60468c04b596 Azure: [PENDING](https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=12488) 
   
   <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


[GitHub] [hudi] hudi-bot commented on pull request #7020: [HUDI-5069] TestInlineCompaction.testSuccessfulCompactionBasedOnNumAndTime is flaky

Posted by GitBox <gi...@apache.org>.
hudi-bot commented on PR #7020:
URL: https://github.com/apache/hudi/pull/7020#issuecomment-1288365144

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "c1f5e56dcb463d42ee57af37502846ce68528628",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=12425",
       "triggerID" : "c1f5e56dcb463d42ee57af37502846ce68528628",
       "triggerType" : "PUSH"
     }, {
       "hash" : "04d5ca0a11f5f8568f2d389dc4ec60468c04b596",
       "status" : "FAILURE",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=12488",
       "triggerID" : "04d5ca0a11f5f8568f2d389dc4ec60468c04b596",
       "triggerType" : "PUSH"
     }, {
       "hash" : "23754c9d84c66721016d846ca6a20614626baa35",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=12502",
       "triggerID" : "23754c9d84c66721016d846ca6a20614626baa35",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 04d5ca0a11f5f8568f2d389dc4ec60468c04b596 Azure: [FAILURE](https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=12488) 
   * 23754c9d84c66721016d846ca6a20614626baa35 Azure: [PENDING](https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=12502) 
   
   <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


[GitHub] [hudi] xicm commented on a diff in pull request #7020: [HUDI-5069] TestInlineCompaction.testSuccessfulCompactionBasedOnNumAndTime is flaky

Posted by GitBox <gi...@apache.org>.
xicm commented on code in PR #7020:
URL: https://github.com/apache/hudi/pull/7020#discussion_r1004133127


##########
hudi-client/hudi-spark-client/src/test/java/org/apache/hudi/table/action/compact/TestInlineCompaction.java:
##########
@@ -229,6 +229,9 @@ public void testSuccessfulCompactionBasedOnNumAndTime() throws Exception {
 
       // Then: ensure no compaction is executed since there are only 3 delta commits
       assertEquals(3, metaClient.getActiveTimeline().getWriteTimeline().countInstants());
+
+      // Ensure the elapsed time > INLINE_COMPACT_TIME_DELTA_SECONDS
+      Thread.sleep(60 * 1000);

Review Comment:
   Another cause is the poor performance of my laptop, this is why this UT is successful on Azure too.



-- 
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


[GitHub] [hudi] hudi-bot commented on pull request #7020: [HUDI-5069] TestInlineCompaction.testSuccessfulCompactionBasedOnNumAndTime is flaky

Posted by GitBox <gi...@apache.org>.
hudi-bot commented on PR #7020:
URL: https://github.com/apache/hudi/pull/7020#issuecomment-1288361616

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


[GitHub] [hudi] hudi-bot commented on pull request #7020: [HUDI-5069] TestInlineCompaction.testSuccessfulCompactionBasedOnNumAndTime is flaky

Posted by GitBox <gi...@apache.org>.
hudi-bot commented on PR #7020:
URL: https://github.com/apache/hudi/pull/7020#issuecomment-1288044471

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


[GitHub] [hudi] hudi-bot commented on pull request #7020: [HUDI-5069] TestInlineCompaction.testSuccessfulCompactionBasedOnNumAndTime is flaky

Posted by GitBox <gi...@apache.org>.
hudi-bot commented on PR #7020:
URL: https://github.com/apache/hudi/pull/7020#issuecomment-1287148689

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


[GitHub] [hudi] hudi-bot commented on pull request #7020: [HUDI-5069] TestInlineCompaction.testSuccessfulCompactionBasedOnNumAndTime is flaky

Posted by GitBox <gi...@apache.org>.
hudi-bot commented on PR #7020:
URL: https://github.com/apache/hudi/pull/7020#issuecomment-1286871795

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "c1f5e56dcb463d42ee57af37502846ce68528628",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "c1f5e56dcb463d42ee57af37502846ce68528628",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * c1f5e56dcb463d42ee57af37502846ce68528628 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


[GitHub] [hudi] hudi-bot commented on pull request #7020: [HUDI-5069] TestInlineCompaction.testSuccessfulCompactionBasedOnNumAndTime is flaky

Posted by GitBox <gi...@apache.org>.
hudi-bot commented on PR #7020:
URL: https://github.com/apache/hudi/pull/7020#issuecomment-1286878033

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


[GitHub] [hudi] xicm commented on pull request #7020: [HUDI-5069] TestInlineCompaction.testSuccessfulCompactionBasedOnNumAndTime is flaky

Posted by GitBox <gi...@apache.org>.
xicm commented on PR #7020:
URL: https://github.com/apache/hudi/pull/7020#issuecomment-1288335284

   This test fails on my laptop, succeeds on Azure. I guess my laptop is too slow, the elapsed time reaches INLINE_COMPACT_TIME_DELTA_SECONDS quickly, so the compaction is executed earlier.


-- 
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


[GitHub] [hudi] xicm commented on a diff in pull request #7020: [HUDI-5069] TestInlineCompaction.testSuccessfulCompactionBasedOnNumAndTime is flaky

Posted by GitBox <gi...@apache.org>.
xicm commented on code in PR #7020:
URL: https://github.com/apache/hudi/pull/7020#discussion_r1004130734


##########
hudi-client/hudi-spark-client/src/test/java/org/apache/hudi/table/action/compact/TestInlineCompaction.java:
##########
@@ -229,6 +229,9 @@ public void testSuccessfulCompactionBasedOnNumAndTime() throws Exception {
 
       // Then: ensure no compaction is executed since there are only 3 delta commits
       assertEquals(3, metaClient.getActiveTimeline().getWriteTimeline().countInstants());
+
+      // Ensure the elapsed time > INLINE_COMPACT_TIME_DELTA_SECONDS
+      Thread.sleep(60 * 1000);

Review Comment:
   I run this test on my laptop and get an assert exception
   ```
   org.opentest4j.AssertionFailedError: Expect baseInstant to be less than or equal to latestDeltaCommit ==> 
   Expected :true
   Actual   :false
   <Click to see difference>
   
   
   	at org.junit.jupiter.api.AssertionUtils.fail(AssertionUtils.java:55)
   	at org.junit.jupiter.api.AssertTrue.assertTrue(AssertTrue.java:40)
   	at org.junit.jupiter.api.Assertions.assertTrue(Assertions.java:193)
   	at org.apache.hudi.table.action.compact.CompactionTestBase.lambda$validateDeltaCommit$0(CompactionTestBase.java:103)
   	at java.util.ArrayList.forEach(ArrayList.java:1257)
   	at org.apache.hudi.table.action.compact.CompactionTestBase.validateDeltaCommit(CompactionTestBase.java:95)
   	at org.apache.hudi.table.action.compact.CompactionTestBase.runNextDeltaCommits(CompactionTestBase.java:148)
   	at org.apache.hudi.table.action.compact.TestInlineCompaction.testSuccessfulCompactionBasedOnNumAndTime(TestInlineCompaction.java:227)
   ```
   
   The original ut has two conditions: 
   1. the elapsed time should less than 20s when the 3rd delta commits finishes. 
   2. the elapsed time should greater than 20s when the 4th delta commits finishes. 
   
   Actually, the elapsed time reaches 20s  when the 3rd delta commits finishes on my laptop, the compaction is executed earlier than expected.
   
   So I increase the INLINE_COMPACT_TIME_DELTA_SECONDS  to ensure 3 delta commits can be finished in 60s. The sleep is to ensure compaction can be executed after the 4th commits.
   
   



-- 
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


[GitHub] [hudi] xicm closed pull request #7020: [HUDI-5069] TestInlineCompaction.testSuccessfulCompactionBasedOnNumAndTime is flaky

Posted by GitBox <gi...@apache.org>.
xicm closed pull request #7020: [HUDI-5069] TestInlineCompaction.testSuccessfulCompactionBasedOnNumAndTime is flaky
URL: https://github.com/apache/hudi/pull/7020


-- 
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


[GitHub] [hudi] hudi-bot commented on pull request #7020: [HUDI-5069] TestInlineCompaction.testSuccessfulCompactionBasedOnNumAndTime is flaky

Posted by GitBox <gi...@apache.org>.
hudi-bot commented on PR #7020:
URL: https://github.com/apache/hudi/pull/7020#issuecomment-1288524386

   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "c1f5e56dcb463d42ee57af37502846ce68528628",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=12425",
       "triggerID" : "c1f5e56dcb463d42ee57af37502846ce68528628",
       "triggerType" : "PUSH"
     }, {
       "hash" : "04d5ca0a11f5f8568f2d389dc4ec60468c04b596",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=12488",
       "triggerID" : "04d5ca0a11f5f8568f2d389dc4ec60468c04b596",
       "triggerType" : "PUSH"
     }, {
       "hash" : "23754c9d84c66721016d846ca6a20614626baa35",
       "status" : "SUCCESS",
       "url" : "https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=12502",
       "triggerID" : "23754c9d84c66721016d846ca6a20614626baa35",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * 23754c9d84c66721016d846ca6a20614626baa35 Azure: [SUCCESS](https://dev.azure.com/apache-hudi-ci-org/785b6ef4-2f42-4a89-8f0e-5f0d7039a0cc/_build/results?buildId=12502) 
   
   <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


[GitHub] [hudi] xicm commented on a diff in pull request #7020: [HUDI-5069] TestInlineCompaction.testSuccessfulCompactionBasedOnNumAndTime is flaky

Posted by GitBox <gi...@apache.org>.
xicm commented on code in PR #7020:
URL: https://github.com/apache/hudi/pull/7020#discussion_r1004130734


##########
hudi-client/hudi-spark-client/src/test/java/org/apache/hudi/table/action/compact/TestInlineCompaction.java:
##########
@@ -229,6 +229,9 @@ public void testSuccessfulCompactionBasedOnNumAndTime() throws Exception {
 
       // Then: ensure no compaction is executed since there are only 3 delta commits
       assertEquals(3, metaClient.getActiveTimeline().getWriteTimeline().countInstants());
+
+      // Ensure the elapsed time > INLINE_COMPACT_TIME_DELTA_SECONDS
+      Thread.sleep(60 * 1000);

Review Comment:
   Hi @nsivabalan 
   I run this test on my laptop and get an assert exception
   ```
   org.opentest4j.AssertionFailedError: Expect baseInstant to be less than or equal to latestDeltaCommit ==> 
   Expected :true
   Actual   :false
   <Click to see difference>
   
   
   	at org.junit.jupiter.api.AssertionUtils.fail(AssertionUtils.java:55)
   	at org.junit.jupiter.api.AssertTrue.assertTrue(AssertTrue.java:40)
   	at org.junit.jupiter.api.Assertions.assertTrue(Assertions.java:193)
   	at org.apache.hudi.table.action.compact.CompactionTestBase.lambda$validateDeltaCommit$0(CompactionTestBase.java:103)
   	at java.util.ArrayList.forEach(ArrayList.java:1257)
   	at org.apache.hudi.table.action.compact.CompactionTestBase.validateDeltaCommit(CompactionTestBase.java:95)
   	at org.apache.hudi.table.action.compact.CompactionTestBase.runNextDeltaCommits(CompactionTestBase.java:148)
   	at org.apache.hudi.table.action.compact.TestInlineCompaction.testSuccessfulCompactionBasedOnNumAndTime(TestInlineCompaction.java:227)
   ```
   
   The original ut has two conditions: 
   1. the elapsed time should less than 20s when the 3rd delta commits finishes. 
   2. the elapsed time should greater than 20s when the 4th delta commits finishes. 
   
   Actually, the elapsed time reaches 20s  when the 3rd delta commits finishes on my laptop, the compaction is executed earlier than expected.
   
   So I increase the INLINE_COMPACT_TIME_DELTA_SECONDS  to ensure 3 delta commits can be finished in 60s. The sleep is to ensure compaction can be executed after the 4th commits.
   
   



-- 
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


[GitHub] [hudi] nsivabalan commented on a diff in pull request #7020: [HUDI-5069] TestInlineCompaction.testSuccessfulCompactionBasedOnNumAndTime is flaky

Posted by GitBox <gi...@apache.org>.
nsivabalan commented on code in PR #7020:
URL: https://github.com/apache/hudi/pull/7020#discussion_r1003859249


##########
hudi-client/hudi-spark-client/src/test/java/org/apache/hudi/table/action/compact/TestInlineCompaction.java:
##########
@@ -229,6 +229,9 @@ public void testSuccessfulCompactionBasedOnNumAndTime() throws Exception {
 
       // Then: ensure no compaction is executed since there are only 3 delta commits
       assertEquals(3, metaClient.getActiveTimeline().getWriteTimeline().countInstants());
+
+      // Ensure the elapsed time > INLINE_COMPACT_TIME_DELTA_SECONDS
+      Thread.sleep(60 * 1000);

Review Comment:
   may I know why its flaky and why would this fix mitigate it. From what I see, we are setting trigger strategy to NUM_AND_TIME. 
   why switching from 20 to 60 secs would work consistently ? 
   



-- 
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