OS API 1.1 has id and uuid in server details

Bug #804093 reported by Mark Washenberger
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
Medium
Brian Waldon

Bug Description

For example, in this response:

{
    "server": {
        "addresses": {
            "private": [],
            "public": []
        },
        "adminPass": "my_password",
        "flavorRef": "http://127.0.0.1:8774/v1.1/flavors/1",
        "hostId": "",
        "id": 33,
        "imageRef": 3,
        "links": [
            {
                "href": "http://127.0.0.1:8774/v1.1/servers/33",
                "rel": "self"
            },
            {
                "href": "http://127.0.0.1:8774/v1.1/servers/33",
                "rel": "bookmark",
                "type": "application/json"
            },
            {
                "href": "http://127.0.0.1:8774/v1.1/servers/33",
                "rel": "bookmark",
                "type": "application/xml"
            }
        ],
        "metadata": {
            "key1": "value1",
            "key2": "value2"
        },
        "name": "testserver",
        "status": "BUILD",
        "uuid": "97ce15ba-32b3-4c8b-b5b0-e51f2ed3add2"
    }
}

I believe there should only be the 'id' field, and its value should be the value of the 'uuid' field.

Tags: osapi-v1.1

Related branches

Revision history for this message
Thierry Carrez (ttx) wrote :

Looking at the spec, the uuid field is certainly superfluous, but I'm not sure its value should replace the one under id.

Changed in nova:
status: New → Incomplete
Revision history for this message
Thierry Carrez (ttx) wrote :

@Mark: Could you motivate a bit more this id = uuid request ?

Brian Waldon (bcwaldon)
Changed in nova:
assignee: nobody → Brian Waldon (bcwaldon)
status: Incomplete → In Progress
Revision history for this message
Brian Waldon (bcwaldon) wrote :

@Thierry: I think there are two motives here --
1) The spec indicates communicating a single 'id' field
2) We do not need to provide two unique fields to the user

Thierry Carrez (ttx)
Changed in nova:
importance: Undecided → Medium
Brian Waldon (bcwaldon)
tags: added: osapi-v1.1
Changed in nova:
assignee: Brian Waldon (bcwaldon) → nobody
status: In Progress → Triaged
Brian Waldon (bcwaldon)
Changed in nova:
assignee: nobody → Brian Waldon (bcwaldon)
status: Triaged → In Progress
Revision history for this message
Openstack Gerrit (openstack-gerrit) wrote : Fix merged to nova (master)

Reviewed: https://review.openstack.org/964
Committed: http://github.com/openstack/nova/commit/e1a743a7eab1aaa8686873fc94249cefebd90e7c
Submitter: Jenkins
Branch: master

 status fixcommitted
 done

commit e1a743a7eab1aaa8686873fc94249cefebd90e7c
Author: Mark Washenberger <email address hidden>
Date: Wed Oct 19 14:12:23 2011 -0400

    Use UUIDs instead of IDs for OSAPI servers.

    Continues to support both UUIDs and IDs in the compute and db layers,
    but only exposes UUIDs in the ID fields of OSAPI responses. Technically,
    old ID-based URIs still work, but you likely can't find them any longer.
    This only affects servers--images and flavors still use integer IDs.

    Fixes bug 804093

    Change-Id: Iecf25c5402f355dd3f227b87a936fcc1b81371b6

Changed in nova:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in nova:
milestone: none → essex-1
Thierry Carrez (ttx)
Changed in nova:
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in nova:
milestone: essex-1 → 2012.1
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.