linera_core::client
: rely on sparse processing of certificates for batching
#4770
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.
Motivation
#4755 batches blob downloads using
required_blob_ids()
, butstore_blobs()
will still fail to store some blobs if their certificates haven't yet been processed, resulting in linear blob download again for those blobs.I believed certificates missing ancestors would be rejected, so there was no point trying to figure out their blobs. In fact, we now think they will be handled sparsely, which means we can collect their blob requirements as we process them.
This should mean we can batch even more blob downloads.
Proposal
Use the
BlobsNotFound
return path ofhandle_certificate
to find the blobs to download, instead of relying directly onrequired_blob_ids()
.Test Plan
CI.
Release Plan
(Experimentally, this change doesn't make enough of a difference over #4755 to be worth backporting.)
Links