Re: rest api json format incomplet informations

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



You have found a bug in the underlying ceph command.  One can see the
same thing using "ceph -f json-pretty osd dump", we get an dict with
the same "pool_snap_info" key used more than once, like this:
          "pool_snaps": { "pool_snap_info": { "snapid": 1,
                  "stamp": "2013-11-25 18:27:34.152418",
                  "name": "test4.1"},
              "pool_snap_info": { "snapid": 2,
                  "stamp": "2013-11-25 18:27:36.370861",
                  "name": "test4.2"}},

When deserialized and then serialized by a JSON library such as the
python one, this malformed dict results in one of those entries being
arbitrarily dropped.

I have opened a ticket: http://tracker.ceph.com/issues/6894

Cheers,
John

On Mon, Nov 25, 2013 at 12:21 PM, eric mourgaya <eric.mourgaya@xxxxxxxxx> wrote:
> Hi,
>
> I'am trying to list  snapshots of pool  using  ceph-rest-api. The json
> format only display the last snapshot of the  pool not all.
> the ceph version is ceph version 0.67.3
> (408cd61584c72c0d97b774b3d8f95c6b1b06341a)
>
>
> http://@ip/api/v0.1/osd/dump  :
>
>
> <pool_snaps><pool_snap_info><snapid>3</snapid><stamp>2013-11-25
> 11:37:34.695874</stamp><name>ericsnap1</name></pool_snap_info><pool_snap_info><snapid>4</snapid><stamp>2013-11-25
> 11:40:30.832976</stamp><name>ericsnap2</name></pool_snap_info><pool_snap_info><snapid>5</snapid><stamp>2013-11-25
> 12:40:02.365069</stamp><name>ericsnap2wq</name></pool_snap_info>
>
> versus
>
> http://@ip/api/v0.1/osd/dump.json or with
> headers={"Accept":"application/json"}
>
>  "pool_snaps": {
>           "pool_snap_info": {
>             "stamp": "2013-11-25 12:40:02.365069",
>             "snapid": 5,
>             "name": "ericsnap2wq"
>           }
>         },
>
>  I
> have you also have the same problem?
>
>
>
> --
> Eric Mourgaya,
>
>
> Respectons la planete!
> Luttons contre la mediocrite!
>
> _______________________________________________
> ceph-users mailing list
> ceph-users@xxxxxxxxxxxxxx
> http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com
>
_______________________________________________
ceph-users mailing list
ceph-users@xxxxxxxxxxxxxx
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com




[Index of Archives]     [Information on CEPH]     [Linux Filesystem Development]     [Ceph Development]     [Ceph Large]     [Ceph Dev]     [Linux USB Development]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [xfs]


  Powered by Linux