-
Notifications
You must be signed in to change notification settings - Fork 4.1k
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
[6.0.0] [remote] Respect whether the server supports action cache updates #16724
Merged
meteorcloudy
merged 3 commits into
bazelbuild:release-6.0.0
from
EngFlow:yannic-cp-128d833fee99f8a43bc4de82cbec752e4ce6fb47
Nov 10, 2022
Merged
[6.0.0] [remote] Respect whether the server supports action cache updates #16724
meteorcloudy
merged 3 commits into
bazelbuild:release-6.0.0
from
EngFlow:yannic-cp-128d833fee99f8a43bc4de82cbec752e4ce6fb47
Nov 10, 2022
Conversation
This file contains 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
…ates Only a subset of users may be allowed to update the action cache (e.g., only CI but not devs). Today, there are 2 ways to achive the desired behavior: - `GetCapabilities` returning that all users are allowed to update, and `UpdateActionResult` returning an error that Bazel prints and ignores, or - have the users that are not allowed to update the action cache set `--remote_upload_local_results=false`. Why don't we instead respect whether the remote cache supports uploading action results? Note that this requires support from the remote system to fully work (i.e., it needs to return `update_enabled = false` for users that don't have permission). Otherwise, Bazel's behavior will be the same as before this change: failed `UpdateActionResult` do not cause the build to fail. The only change this introduces is that Bazel will no longer error if `--remote_upload_local_results=true` and `GetCapabilities` returning `update_enabled = false`. Closes bazelbuild#16624. PiperOrigin-RevId: 486901751 Change-Id: I0991f6891e21711df1e23ae0998a8bc95e2389bc
ShreeM01
added
team-Remote-Exec
Issues and PRs for the Execution (Remote) team
awaiting-review
PR is awaiting review from an assigned reviewer
labels
Nov 10, 2022
@coeuvre Please LGTM if this looks good to be cherry-picked for 6.0 ;) |
coeuvre
approved these changes
Nov 10, 2022
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.
Yes, it's safe to cherry-pick this into 6.0.
@Yannic Can you rebase? |
thanks! done |
Yannic
deleted the
yannic-cp-128d833fee99f8a43bc4de82cbec752e4ce6fb47
branch
November 10, 2022 11:19
This was referenced May 30, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
awaiting-review
PR is awaiting review from an assigned reviewer
team-Remote-Exec
Issues and PRs for the Execution (Remote) team
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.
Only a subset of users may be allowed to update the action cache (e.g., only CI but not devs).
Today, there are 2 ways to achive the desired behavior:
GetCapabilities
returning that all users are allowed to update, andUpdateActionResult
returning an error that Bazel prints and ignores, or--remote_upload_local_results=false
.Why don't we instead respect whether the remote cache supports uploading action results?
Note that this requires support from the remote system to fully work (i.e., it needs to return
update_enabled = false
for users that don't have permission). Otherwise, Bazel's behavior will be the same as before this change: failedUpdateActionResult
do not cause the build to fail. The only change this introduces is that Bazel will no longer error if--remote_upload_local_results=true
andGetCapabilities
returningupdate_enabled = false
.Closes #16624.
PiperOrigin-RevId: 486901751
Change-Id: I0991f6891e21711df1e23ae0998a8bc95e2389bc