HDDS-8697 Recon - Expose API for total count for blocks pending for deletion.#4791
HDDS-8697 Recon - Expose API for total count for blocks pending for deletion.#4791ArafatKhan2198 wants to merge 1 commit intoapache:masterfrom
Conversation
|
@devmadhuu @adoroszlai @symious Can you please take a look !! |
| * } | ||
| * ] | ||
| * "totalCount": 1000, | ||
| * "containerStateBlockInfoListMap": { |
There was a problem hiding this comment.
@ArafatKhan2198 thanks for working on this patch, We need total count and unreplicated and replicated size mapped to those blocks. You should provide a new API, below API is only based on pagination.
| try ( | ||
| Table<Long, | ||
| StorageContainerDatanodeProtocolProtos.DeletedBlocksTransaction> | ||
| deletedBlocksTable = DELETED_BLOCKS.getTable(this.scmDBStore)) { |
There was a problem hiding this comment.
Pls don't change in existing API. This API should work based on pagination params only.
| Table<Long, | ||
| StorageContainerDatanodeProtocolProtos.DeletedBlocksTransaction> | ||
| deletedBlocksTable = DELETED_BLOCKS.getTable(this.scmDBStore)) { | ||
| long totalCount = deletedBlocksTable.getEstimatedKeyCount(); |
There was a problem hiding this comment.
This doesn't give correct count. We should not use this method.
|
/pending |
|
Thank you very much for the patch. I am closing this PR temporarily as there was no activity recently and it is waiting for response from its author. It doesn't mean that this PR is not important or ignored: feel free to reopen the PR at any time. It only means that attention of committers is not required. We prefer to keep the review queue clean. This ensures PRs in need of review are more visible, which results in faster feedback for all PRs. If you need ANY help to finish this PR, please contact the community on the mailing list or the slack channel." |
What changes were proposed in this pull request?
Improvements have been made to the existing
BlocksEndpointAPI response. Now, the total count of blocks pending deletion is displayed in the API response. The updated response will appear as follows:This new response includes the total count of pending deletions blocks and a list of containers, each with their state, container ID, list of local IDs, count of local IDs, and transaction ID.
What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-8697
How was this patch tested?
Added new and made modifications to the existing UT's