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-33932][checkpointing] Add retry mechanism in RocksDBStateUploader #23986
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the contribution, I've left a couple of comments. Apart of those could you implement a test for this in RocksDBStateUploader
? You could inject a testing CheckpointStreamFactory
that throws a configured amount of exceptions first.
private static final int DEFAULT_RETRY_TIMES = 3; | ||
|
||
private static final Duration DEFAULT_RETRY_DELAY = Duration.ofSeconds(1L); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be configurable and most likely in the first release default to the current behaviour.
stateScope, | ||
closeableRegistry, | ||
tmpResourcesRegistry)), | ||
() -> { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please extract to separate method.
TimeUnit.MILLISECONDS.sleep( | ||
retryStrategy | ||
.getRetryDelay() | ||
.toMillis()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It would be better to not synchronously wait on the timeout, and free up the thread pool to do other things.
Sorry for jumping in but may I ask about the current status? |
What is the purpose of the change
Add retry mechanism in RocksDBStateUploader
Brief change log
Verifying this change
This change added tests and can be verified as follows:
Does this pull request potentially affect one of the following parts:
@Public(Evolving)
: noDocumentation