Comment 1 for bug 943053

Revision history for this message
Vish Ishaya (vishvananda) wrote :

This is actually a nasty usability issue and makes the api look unprofessional.

Create Volume Request: JSON

{
    "volume": {
        "display_name": "vol-001",
        "display_description": "Another volume.",
        "size": 30,
        "volume_type": "289da7f8-6440-407c-9fb4-7db01ec49164",
        "metadata": {"contents": "junk"},
        "availability_zone": "us-east1"
     }
}

Create Volume Response: JSON
{
    "volume": {
        "id": "521752a6-acf6-4b2d-bc7a-119f9148cd8c",
        "displayName": "vol-001",
        "displayDescription": "Another volume.",
        "size": 30,
        "volumeType": "289da7f8-6440-407c-9fb4-7db01ec49164",
        "metadata": {"contents": "junk"},
        "availabilityZone": "us-east1",
        "snapshotId": null,
        "attachments": [],
        "createdAt": "2012-02-14T20:53:07Z"
     }
}

It would be great if we could switch it but still support the old syntax for anyone who happens to be using it. But we should just publish the new syntax in the api docs. Supporting the old syntax will allow us to get through the merge gate as well.