-
Notifications
You must be signed in to change notification settings - Fork 4.4k
Communicate persistent worker protocol to remote execution service #28489
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
Open
armandomontanez
wants to merge
1
commit into
bazelbuild:master
Choose a base branch
from
armandomontanez:communicate-worker-protocol
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+18
−7
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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.
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.
Since the worker protocol is specific to Bazel, we could consider prefixing this with
bazel-.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'm also not hugely in love with the fact that this looks different from
persistentWorkerKey. It probably makes sense to just solve this with a short docs page that lists out established platform properties.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.
Is it necessarily specific to Bazel? The protos are defined by Bazel of course, but other build tools and adapters may deal with these keys.
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.
Not necessarily, other build systems could also use persistent workers. In practice I don't know of any such other usage (perhaps buck2?). If we think that this is worth using more widely, it would make sense to include in the REAPI spec.
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 think it would be great to codify persistent workers in RE API. I don't think much would actually need to change in the protocol, but we'd need to document the conventions that Bazel follows (so
persistentWorkerKey,requires-worker-protocolor whatever we call it, the--persistent_workerflag, separate of arguments between workers and actions).What's the process for an RE change like that? Would it go through https://github.com/bazelbuild/proposals?
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.
https://github.com/bazelbuild/remote-apis would be the best place to discuss this in the form of a PR and/or in the monthly meeting.
Uh oh!
There was an error while loading. Please reload this page.
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.
Note that, even though Bazel might the only client implementation that supports them, there are already multiple server implementations of persistent workers (AFAIK, Engflow and BuildBuddy both implement it; there might be more).
Unfortunately, the spec itself (which is maintained separately from Bazel at http://github.com/bazelbuild/remote-apis) is currently silent on persistent workers; they effectively operate as an unstandardized extension to the protocol (though my understanding is that existing implementations are convergent).
I agree that it would be desirable to eventually make persistent workers part of the spec, but so far nobody has tried to move it forward. If you'd like to get the discussion started, I think the most productive way to do so is to attend our monthly working group meeting. If that doesn't work for you, opening an issue on http://github.com/bazelbuild/remote-apis is fine too.
On the other hand, I don't think that this particular PR needs to be gated on standardizing the existing spec. I would like, however, to see some indication from existing implementations that they're willing to implement it before we do so on the Bazel side.
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.
+1 to moving in parallel. I'll drop in to the sync next week. It seems worthwhile doing the work of standardizing this since not handling this extension tends to result in hard failures.