-
Notifications
You must be signed in to change notification settings - Fork 3.9k
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
storage: make key/value printing explicitly redactable #81495
Conversation
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.
Thanks. Where are the unit tests?
Reviewed 1 of 3 files at r1, 2 of 2 files at r2, all commit messages.
Reviewable status:complete! 0 of 0 LGTMs obtained (waiting on @nerdroychan)
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.
Looks great, would be easy to add a test in mvcc_test.go
that basically does
func TestFormatKeyAndValues(t *testing.T) {
// ..usual test setup..
// Test that values and keys are printed with redaction markets.
require.Equal(t, FormatBytesAsKey([]byte("foo")), "‹foo›")
require.Equal(t, FormatBytesAsValue([]byte("foo")), "‹foo›")
}
Reviewed all commit messages.
Reviewable status:complete! 0 of 0 LGTMs obtained (waiting on @nerdroychan)
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.
Thanks. The unit tests are added to mvcc_test.go
.
Reviewable status:
complete! 0 of 0 LGTMs obtained (waiting on @itsbilal and @knz)
This commit makes the formatting functions in storage/enginepb return explicitly redactable strings. Resolve #70288. Release note: None
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.
Reviewed 2 of 2 files at r3, all commit messages.
Reviewable status:complete! 0 of 0 LGTMs obtained (waiting on @itsbilal)
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.
Reviewed all commit messages.
Reviewable status:complete! 1 of 0 LGTMs obtained (waiting on @nerdroychan)
bors r=itsbilal,knz |
Build failed (retrying...): |
Build succeeded: |
This commit makes the formatting functions in storage/enginepb
return explicitly redactable strings.
Resolve #70288.
Release note: None