[ 
https://issues.apache.org/jira/browse/HDDS-8210?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17886748#comment-17886748
 ] 

Siyao Meng commented on HDDS-8210:
----------------------------------

[~erose] Yup. I've put the details in the PR description:
{quote}For SchemaV3 {{block_data}} table, we could further nest entries inside 
another map. With the outer-most layer being {{{}containerId{}}}.

e.g. Currently (with the separator change in this PR), the JSON key for an 
entry inside V3 {{block_data}} is {{{}containerId|blockId{}}}:
{code:java}
{ "2|3": {
  "blockID": {
    "containerBlockID": {
      "containerID": 2,
      "localID": 3
    },
    "blockCommitSequenceId": 0
  },
  "metadata": {},
  "size": 0
}, "2|4": {
  "blockID": {
    "containerBlockID": {
      "containerID": 2,
      "localID": 4
    },
    "blockCommitSequenceId": 0
  },
  "metadata": {},
  "size": 0
} } {code}
With another layer, the output could become even cleaner, making it easier to 
be filtered using {{{}jq{}}}:
{code:java}
{
  "2": {
    "3": {
      "blockID": {
        "containerBlockID": {
          "containerID": 2,
          "localID": 3
        },
        "blockCommitSequenceId": 0
      },
      "metadata": {},
      "size": 0
    },
    "4": {
      "blockID": {
        "containerBlockID": {
          "containerID": 2,
          "localID": 4
        },
        "blockCommitSequenceId": 0
      },
      "metadata": {},
      "size": 0
    }
  }
} {code}
 
{quote}

> For SchemaV3 block_data table, nest blockId inside a containerId map
> --------------------------------------------------------------------
>
>                 Key: HDDS-8210
>                 URL: https://issues.apache.org/jira/browse/HDDS-8210
>             Project: Apache Ozone
>          Issue Type: Sub-task
>            Reporter: Siyao Meng
>            Assignee: Dave Teng
>            Priority: Major
>
> See "Future potential improvement" section in this PR for the context:
> https://github.com/apache/ozone/pull/4420



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to