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

kvstore: add GetMultiple #220

Closed
wants to merge 1 commit into from
Closed

kvstore: add GetMultiple #220

wants to merge 1 commit into from

Conversation

setrofim
Copy link
Collaborator

Add GetMultiple method to IKVStore that allows fetching values for multiple keys from a store with a single call. This simplifies the usage of the store inside trusted services and can potentially improve performance for remote store implementations where call overhead may be non-trivial.

This addresses #207

Add GetMultiple method to IKVStore that allows fetching values for
multiple keys from a store with a single call. This simplifies the usage
of the store inside trusted services and can potentially improve
performance for remote store implementations where call overhead may be
non-trivial.

Signed-off-by: Sergei Trofimov <[email protected]>

o.logger.Debugw("obtained endorsements", "endorsements", endorsements)
multEndorsements = append(multEndorsements, endorsements...)
endorsements, err := o.EnStore.GetMultiple(appraisal.EvidenceContext.ReferenceIds)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@setrofim : Why the same API is not applicable to line 448-452 ?

@yogeshbdeshpande
Copy link
Collaborator

Also, is the same not true for Add() Interface, used with one example on main branch:
trustedservices_grpc.go line 318-322

@thomas-fossati
Copy link
Contributor

Just checking since I have lost the context: is this change still required?

@setrofim
Copy link
Collaborator Author

setrofim commented Aug 27, 2024

Just checking since I have lost the context: is this change still required?

It was more of a nice-to-have refactor. Given that we have larger issues looming around KVStore, I don't think this is worth the churn.

@setrofim setrofim closed this Aug 27, 2024
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.

3 participants