-
Notifications
You must be signed in to change notification settings - Fork 4.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add flag `--experimental_remote_cache_lease_extension`, which when set, Bazel will create a background thread periodically sending `FindMissingBlobs` requests to CAS during the build. 1. All the outputs that were not downloaded are within the scope of lease extension. The outputs are acquired from skyframe by traversing the action graph. 2. Lease extension starts after any action was built and ends after execution phase ended. The frequency is related to `--experimental_remote_cache_ttl`. 3. Lease extensions are performed on action basis, not by collecting all outputs and issue one giant `FindMissingBlobs`. - Collecting all outputs might increase memory watermark and cause OOM. - Sending one `FindMissingBlobs` request per action may increase the overhead of network roundtrip, but the cost should be saturated given that the lease extension happens at background and is not wall time critical. 4. For an incremental build, the same applies: lease extension starts after any action was executed. - We don't want lease extension blocking action execution, nor affecting build performance. - Since we have TTL based cache discarding, any expired blobs will be discarded. - Leases of blobs that are not downloaded, still used by this build (because they are referenced by skyframe) will be extended as normal. Part of #16660. Closes #17944. PiperOrigin-RevId: 544032753 Change-Id: Iafe8b96c48abbb2e67302cd7a2f06f97ab43f825
- Loading branch information
1 parent
15c412e
commit 1a2b792
Showing
11 changed files
with
449 additions
and
10 deletions.
There are no files selected for viewing
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
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
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
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
Oops, something went wrong.