I assume you're using Glance client, if so, by default, when you issuing command 'glance image-list', it will call /v1/images/detail instead of /v1/images, you can use curl or any browser http client to see the difference. Basically, just like the endpoint name, /v1/images/detail will give you more details. See below difference of their response.

Response from /v1/images/detail
{
    "images": [
        {
            "status": "active",
            "deleted_at": null,
            "name": "fedora-21-atomic-3",
            "deleted": false,
            "container_format": "bare",
            "created_at": "2015-09-03T22:56:37.000000",
            "disk_format": "qcow2",
            "updated_at": "2015-09-03T23:00:15.000000",
            "min_disk": 0,
            "protected": false,
            "id": "b940521b-97ff-48d9-a22e-ecc981ec0513",
            "min_ram": 0,
            "checksum": "d3b3da0e07743805dcc852785c7fc258",
            "owner": "5f290ac4b100440b8b4c83fce78c2db7",
            "is_public": true,
            "virtual_size": null,
            "properties": {
                "os_distro": "fedora-atomic"
            },
            "size": 770179072
        }
    ]
}

Response with /v1/images
{
    "images": [
        {
            "name": "fedora-21-atomic-3",
            "container_format": "bare",
            "disk_format": "qcow2",
            "checksum": "d3b3da0e07743805dcc852785c7fc258",
            "id": "b940521b-97ff-48d9-a22e-ecc981ec0513",
            "size": 770179072
        }
    ]
}


On 10/09/15 11:46, Su Zhang wrote:

Hello,

I am hitting an error and its trace passes def index () in glance/registry/api/v1/images.py.

I assume def index() is called by glance image-list. However, while testing glance image-list I realized that def detail() is called under glance/registry/api/v1/images.py instead of def index().

Could someone let me know what's the difference between the two functions? How can I test out def index() under glance/registry/api/v1/images.py through CLI or API?

Thanks,

--
Su Zhang



__________________________________________________________________________
OpenStack Development Mailing List (not for usage questions)
Unsubscribe: [email protected]?subject:unsubscribe
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev

--
Cheers & Best regards,
Fei Long Wang (王飞龙)
--------------------------------------------------------------------------
Senior Cloud Software Engineer
Tel: +64-48032246
Email: [email protected]
Catalyst IT Limited
Level 6, Catalyst House, 150 Willis Street, Wellington
--------------------------------------------------------------------------

__________________________________________________________________________
OpenStack Development Mailing List (not for usage questions)
Unsubscribe: [email protected]?subject:unsubscribe
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev

Reply via email to