HDDS-14957. Separate OpenKeyInfo to differentiate KeyInfo#10170
HDDS-14957. Separate OpenKeyInfo to differentiate KeyInfo#10170YutaLin wants to merge 8 commits intoapache:masterfrom
Conversation
|
Hi @peterxcli, @ivandika3 |
|
Thanks @YutaLin for the patch, but I don't think this is a compatible change since we are changing the DB definition in-place. We need to think further on how to approach this. |
|
IMO it is fine to leave things be unless there is a good reason other than separation of concern (e.g. https://issues.apache.org/jira/browse/HDDS-10611). From the overhead point of view, adding fields to protobuf would not cause increased protobuf size as long as we remember to unassign the fields. |
|
Hey @ivandika3,
Thanks for review, I will close this patch since it's no longer needed. |
|
I was thinking if we could just introduce a open key info serde class that only store a subset of key info, without, no explicitly unassign need, only need to build the data class from the incoming key info in request. |
|
if you agree with my point, let's reopen this and refactor it! thanks! |
|
Hi @peterxcli, that's a great feedback, I will raise another patch. thanks! |
Hi @ivandika3, can you elaborate? |
|
@YutaLin The new OpenKeyInfo proto and KeyInfo proto are not compatible. For example, the field 1 for
No I don't think so, duplicate codec serde might cause performance issues since openKeyTable & openFileTable is in the critical path. I think the approach in #10181 might be enough. |
How about we add a |
What changes were proposed in this pull request?
Use a separate OpenKeyInfo for openKeyTable to differentiate with the final KeyInfo in the keyTable
Please describe your PR in detail:
Base on discussion: #9815 (comment)
We've add
expectedDataGenerationandexpectedETagin KeyInfo but these value should not be stored after commit, otherwise it has space overhead, so we introducedOpenKeyInfoto prevent space waste.What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-14957
How was this patch tested?
Update tests with
OmOpenKeyInfoand run CI Action(https://github.com/YutaLin/ozone/actions/runs/25239339785)