Skip to content
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

ByteStreamBuildEventArtifactUploader: skip reading metadata for files that won't be uploaded #20575

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

christianscott
Copy link
Contributor

@christianscott christianscott commented Dec 17, 2023

Note

draft because I'm not yet sure about the implementation

54% of samples in a profile I took of our build included readPathMetadata()

Screenshot 2023-12-17 at 4 15 23 pm

as far as I can tell, path metadata is only needed for files that are going to be uploaded to the CAS. for builds that use minimal remote uploads, this results in a lot of extra unneeded stats.

this makes a fully cached remote build (cold local) of a large subset of our monorepo 3x faster. I am not totally sure why given that (I think) this function is only used by the bes-uploader thread, but the working theory is that this allows BEP events to be processed more quickly, which keeps the eventQueue small and reducing memory usage

tested with Bazel 6.4.0. have not tested this change because our monorepo is not compatible with Bazel 7.x yet.

Copy link

google-cla bot commented Dec 17, 2023

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

@KipHamiltons
Copy link

What do we need for this one to get over the line @christianscott ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants