HDDS-15664. ozone debug ldb display DeletedBlocksTransactionSummary info#10614
HDDS-15664. ozone debug ldb display DeletedBlocksTransactionSummary info#10614ChenSammi wants to merge 2 commits into
Conversation
priyeshkaratha
left a comment
There was a problem hiding this comment.
Thanks @ChenSammi for the patch. Changes LGTM
adoroszlai
left a comment
There was a problem hiding this comment.
Thanks @ChenSammi for the patch. DBScanner is very generic, but the PR adds tightly coupled parse logic. Can you please explain why this is needed, why STATEFUL_SERVICE_CONFIG is the only column family that needs special care? If the current logic cannot parse it, can it be implemented in a way that helps with any other column families not handled currently?
| } catch (InvalidProtocolBufferException e) { | ||
| LOG.error("Failed to parse {} for key {}", STATEFUL_SERVICE_CONFIG.getName(), SERVICE_NAME, e); | ||
| } catch (IOException e) { | ||
| LOG.error("Failed to parse {} for key {}", STATEFUL_SERVICE_CONFIG.getName(), SERVICE_NAME, e); |
There was a problem hiding this comment.
Duplicate catch blocks, please merge them.
There was a problem hiding this comment.
@adoroszlai , STATEFUL_SERVICE_CONFIG is a table which doesn't belong to a specific feature of SCM, it's used as a key-value store(String -> ByteString) for all SCM features to persist value which need persistent. Currently it's used by container balancer, and Root CA rotation manager, now storage capacity feature. So the element in this table is specific to a feature, not like other tables in SCM, which has the same value data structure.
Currently, DBScanner can display this table with it raw ByteString value, not a understandable format of human, equal to no use during the debug time.
This task aims to covert the ByteString value to a storage capacity feature data structure and display it, so DBScanner will be helpful in the debug of future storage capacity feature. I'm not sure if I explain it clearly enough?
There was a problem hiding this comment.
Thanks @ChenSammi for the explanation.
I would like to suggest some refactoring to reduce hard-coding in DBScanner, and also support container balancer and Root CA rotation manager: adoroszlai@0d5dd70 I can also submit follow-up PR if you prefer.
What changes were proposed in this pull request?
add support in ldb scan command, to display DeletedBlocksTransactionSummary info.
What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-15664
How was this patch tested?
Manual test