-
Notifications
You must be signed in to change notification settings - Fork 334
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
feat: EtcdStore support chroot #2786
Conversation
Signed-off-by: tison <[email protected]>
Signed-off-by: tison <[email protected]>
Signed-off-by: tison <[email protected]>
Signed-off-by: tison <[email protected]>
Signed-off-by: tison <[email protected]>
Signed-off-by: tison <[email protected]>
Signed-off-by: tison <[email protected]>
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## develop #2786 +/- ##
===========================================
- Coverage 84.47% 84.10% -0.38%
===========================================
Files 728 729 +1
Lines 113352 113581 +229
===========================================
- Hits 95756 95526 -230
- Misses 17596 18055 +459 |
cc @MichaelScofield @WenyXu this is a prerequisite for #2734. It still waits for the upstream release but we should be able to review the changes now. |
Signed-off-by: tison <[email protected]>
@@ -146,6 +147,43 @@ impl Txn { | |||
self | |||
} | |||
|
|||
pub fn prepend_root(mut self, root: &[u8]) -> Self { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we put this prepend_root
function in EtcdStore
's Implementation for TxnService
? Other kv backend Implementations don't need it.
Also in doing so, maybe the functions chroot_key_value_with
, key_strip_root
and key_prepend_root
can be better placed in EtcdStore
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The issue is req: TxnRequest,
private. If following your suggestion, we should export this field to pub(crate)
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That is, we need somehow modify the request (key).
Signed-off-by: tison <[email protected]>
Closing in favor of #2734. |
I hereby agree to the terms of the GreptimeDB CLA
What's changed and what's your intention?
To support chroot in etcd, we should take the ownership of KeyValues and thus modify them later.
Checklist
Refer to a related PR or issue link (optional)