Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
[Object Spilling] Remove retries and use a timer instead. #13175
[Object Spilling] Remove retries and use a timer instead. #13175
Changes from 1 commit
b4e4bc6
b292123
975f22d
08c14c1
4fa7903
c6ea3b5
e4dec92
ac573c0
cfe5c58
c5d516f
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
Why do we need to assign success here?
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.
Otherwise it can OOM without any grace period if the spilling is not invoked. (since the last success_ns is not renewed at all)
Then
is not reflected. Let me know if I am missing something!
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.
Shouldn't we be setting last_success_ns_ in the else branch? It seems like we need another state like "waiting for OOM" so we know whether to set vs check the last_success_ns_.
And we should add a unit test for this case because I think it's currently broken:
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.
We also set it if spilling is successful, so it's set whenever a creation/spill succeeds. If neither has succeeded for the grace period, OOM is raised.
So the case raised above is fine--- spilling is attempted in the second create case, and that resets the timer.
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.
I don't think that the spill reset is enough because it won't happen if the spill callback is unsuccessful.
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.
You don't want to reset it on OOM right? Otherwise, it will take a long time to OOM many objects (e.g., 10 seconds * N objects)
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.
Ah, right.
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 check code again (I reflected the comment.)
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.
Also note; I am using -1 as a default value of
oom_start_time_ns_
instead of 0 because otherwise, tests will fail (since the initial fake clock time is 0).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.
Also, added a test case that checks if objects are successfully created after there was no new object created for a long time.