Bug 1956620 - "ceph fs snapshot mirror daemon status" should not use json keys as value
Summary: "ceph fs snapshot mirror daemon status" should not use json keys as value
Keywords:
Status: ASSIGNED
Alias: None
Product: Red Hat Ceph Storage
Classification: Red Hat
Component: CephFS
Version: 5.0
Hardware: All
OS: All
high
low
Target Milestone: ---
: 5.0
Assignee: Venky Shankar
QA Contact: Hemanth Kumar
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-05-04 05:20 UTC by Venky Shankar
Modified: 2021-05-08 13:54 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed:
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Ceph Project Bug Tracker 50537 0 None None None 2021-05-04 05:20:31 UTC

Description Venky Shankar 2021-05-04 05:20:31 UTC
Currently the command outputs:

{
  "14135": {
    "1": {
      "name": "a",
      "directory_count": 0,
      "peers": {
        "ae3f22e6-1c72-4a81-8d5d-eebca3bfd29d": {
          "remote": {
            "client_name": "client.mirror_remote",
            "cluster_name": "site-remote",
            "fs_name": "backup_fs" 
          },
          "stats": {
            "failure_count": 0,
            "recovery_count": 0
          }
        }
      }
    }
  }
}
JSON keys should not be the value, I'm proposing the following JSON:

{
  "daemon_id": "444607",
  "filesystem_id": "1",
  "name": "myfs",
  "directory_count": 0,
  "peers": [
    {
      "uuid": "4a6983c0-3c9d-40f5-b2a9-2334a4659827",
      "remote": {
        "client_name": "client.mirror_remote",
        "cluster_name": "site-remote",
        "fs_name": "backup_fs" 
      },
      "stats": {
        "failure_count": 0,
        "recovery_count": 0
      }
    }
  ]
}
It will make the JSON parsing and unmarshalling into other language type easier.

Comment 1 RHEL Program Management 2021-05-04 05:20:38 UTC
Please specify the severity of this bug. Severity is defined here:
https://bugzilla.redhat.com/page.cgi?id=fields.html#bug_severity.


Note You need to log in before you can comment on or make changes to this bug.