Vine: Forsake functions when library exits.#3742
Merged
btovar merged 10 commits intocooperative-computing-lab:masterfrom Mar 26, 2024
Merged
Vine: Forsake functions when library exits.#3742btovar merged 10 commits intocooperative-computing-lab:masterfrom
btovar merged 10 commits intocooperative-computing-lab:masterfrom
Conversation
Handles the case of a function abandoned by the necessary library.
btovar
approved these changes
Mar 25, 2024
Member
Author
|
Still thinking about this one in two respects: |
70643c6 to
bd7fc68
Compare
that applies to all result codes. Fixes bug whereby forsaken or failed tasks would have stale sandboxes left behind.
Member
Author
|
Since this is an improvement to a corner case and not a critical bug, I think it can wait until after the pending release... |
btovar
approved these changes
Mar 26, 2024
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Proposed changes
Previously, when a library would exit (success or otherwise), two problems resulted:
1 - The function calls sent subsequent to that library would simply sit on the worker doing nothing.
2 - The manager would quickly re-dispatch a library to that same worker, resulting in a tight loop of failures.
This PR fixes these as follows:
1 - The worker now has extended logic for
task_can_fit_eventuallyso that functions will be forsaken if there is no library process at all that could execute them.2 - Forsaken tasks are now handled correctly by deleting their sandboxes once they are retrieved.
3 - The most recent failure of a library is recorded in the library prototype object and used to throttle re-dispatch of failed library tasks.
4 - Fetching of task stdout is factored out of get_result to make the logic of fetching a result more clearly visible.
Post-change actions
Put an 'x' in the boxes that describe post-change actions that you have done.
The more 'x' ticked, the faster your changes are accepted by maintainers.
make testRun local tests prior to pushing.make formatFormat source code to comply with lint policies. Note that some lint errors can only be resolved manually (e.g., Python)make lintRun lint on source code prior to pushing.Additional comments
This section is dedicated to changes that are ambitious or complex and require substantial discussions. Feel free to start the ball rolling.