HDDS-9373. Optimize listKeysLight API further by efficient server-side proto field population #5382
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.
What changes were proposed in this pull request?
We have introduced a lightweight listKeys API as part of HDDS-9079. Implement a lightweight listKeys API (PR #5115), leveraging a trimmed
KeyInfo(BasicKeyInfo) proto object to exclude less relevant fields, such asKeyLocations, which have limited utility on the client side. This implementation utilizes newer server-side Ozone key encapsulations and proto objects as part of HDDS-9079.The primary goal of this enhancement is to skip the deserialization of metadata specific to block information, etc. thus reducing the performance overhead when listing keys. Additionally, we aim to further improve performance by selectively populating the below fields server-side only when the key's configuration differs from that of its associated bucket:
This optimization should lead to reduced payload and server-side processing unless the key is replicated in a configuration distinct from the bucket's default settings. Addressing the review comment as part of this PR.
What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-9373
How was this patch tested?
Existing test cases should cover the code changes