Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[flink] fix unstable test: testAsyncCompactionFileDeletedWhenShutdown #2266

Closed
wants to merge 1 commit into from

Conversation

liming30
Copy link
Contributor

@liming30 liming30 commented Nov 6, 2023

Purpose

Linked issue: close #2231

[flink] fix unstable test: testAsyncCompactionFileDeletedWhenShutdown.

In the original implementation, Thread.sleep(2_000) is used to wait for the thread pool to finish, which does not strictly guarantee that the thread pool is finished. I modified it to use ExecutorService#awaitTermination and increased the timeout to 2 minutes.

Tests

No

API and Format

No

Documentation

No

@leaves12138
Copy link
Contributor

+1

@leaves12138
Copy link
Contributor

this also fixed in #2245

@liming30
Copy link
Contributor Author

liming30 commented Nov 6, 2023

this also fixed in #2245

@leaves12138 hi, I saw that #2245 is waiting in the shutdown of AppendOnlyTableCompactionWorkerOperator. If flink sends a cancel signal to the task, this will interrupt the thread. Is it possible to throw an InterruptedException, causing the subsequent logic to fail to execute?

@leaves12138
Copy link
Contributor

this also fixed in #2245

@leaves12138 hi, I saw that #2245 is waiting in the shutdown of AppendOnlyTableCompactionWorkerOperator. If flink sends a cancel signal to the task, this will interrupt the thread. Is it possible to throw an InterruptedException, causing the subsequent logic to fail to execute?

The close method should not receive a Interrupted signal.

@liming30
Copy link
Contributor Author

liming30 commented Nov 6, 2023

@leaves12138 It seems that TaskCanceler will first interrupt the executingThread of the task, and the a TaskInterrupter will interrupt periodically until the task is closed or timeout.

@liming30
Copy link
Contributor Author

liming30 commented Nov 7, 2023

Closed because it has been fixed in #2245.

@liming30 liming30 closed this Nov 7, 2023
@Aitozi
Copy link
Contributor

Aitozi commented Nov 8, 2023

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug] AppendOnlyTableCompactionWorkerOperatorTest is not stable
3 participants