Project

General

Profile

Bug #23200

invalid JSON returned when querying pool parameters

Added by Wyllys Ingersoll about 6 years ago. Updated almost 6 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
Administration/Usability
Target version:
-
% Done:

0%

Source:
Community (user)
Tags:
Backport:
luminous
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Component(RADOS):
Monitor
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

When requesting JSON formatted results for querying for pool
parameters, the list that comes back is not valid JSON. Its just a
series of records, not a comma separated JSON list.

For example:

# ceph osd pool get cephfs_data all --format json-pretty

{
    "pool": "cephfs_data",
    "pool_id": 1,
    "size": 2
}
{
    "pool": "cephfs_data",
    "pool_id": 1,
    "min_size": 1
}
{
    "pool": "cephfs_data",
    "pool_id": 1,
    "crash_replay_interval": 0
}
{
    "pool": "cephfs_data",
    "pool_id": 1,
    "pg_num": 256
}
...


Note that there are no commas separating the items and the overall
list is not enclosed in [].

This cannot be parsed with standard json tools like the python json
module. I would expect that when requesting JSON, it would return
valid JSON.


Related issues

Copied to RADOS - Backport #23312: luminous: invalid JSON returned when querying pool parameters Resolved

History

#1 Updated by John Spray about 6 years ago

  • Project changed from Ceph to RADOS
  • Category changed from ceph cli to Administration/Usability
  • Component(RADOS) Monitor added

#2 Updated by John Spray about 6 years ago

  • Backport set to luminous

#3 Updated by Chang Liu about 6 years ago

  • Assignee set to Chang Liu

#4 Updated by Chang Liu about 6 years ago

  • Status changed from New to Fix Under Review

#5 Updated by Kefu Chai about 6 years ago

  • Status changed from Fix Under Review to Pending Backport
  • Target version deleted (v12.2.4)
  • Affected Versions v10.2.4 added

#6 Updated by Nathan Cutler about 6 years ago

  • Copied to Backport #23312: luminous: invalid JSON returned when querying pool parameters added

#7 Updated by Nathan Cutler almost 6 years ago

  • Status changed from Pending Backport to Resolved

Also available in: Atom PDF