os-interface create API docs are wrong

Bug #1352950 reported by Matt Riedemann
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
openstack-api-site
Fix Released
Medium
Diane Fleming

Bug Description

Was looking at bug 1338551 and the API docs for the attach_interface create method:

http://docs.openstack.org/api/openstack-compute/2/content/POST_os-interface-v2_createAttachInterface__v2__tenant_id__servers__server_id__os-interface_ext-os-interface.html

The API docs say that port_id is required in the request but it's actually optional:

http://git.openstack.org/cgit/openstack/nova/tree/nova/api/openstack/compute/contrib/attach_interfaces.py#n80

You can send in port_id/net_id/fixed_ips, net_id and port_id are mutually exclusive, and requesting a specific fixed_ip without a net_id is a 400 BadRequest also.

If the port_id isn't provided, the network API will allocate one on the given network. If net_id isn't provided, the network associated with the instance in the network info cache will be used.

The API docs also don't list any error codes, of which there are 400, 404, 409, 500, and 501 (because nova-network doesn't implement this API).

Revision history for this message
Anne Gentle (annegentle) wrote :

Agreed, you can move out of nova if needed, we'll fix in the api-site.

Changed in openstack-api-site:
status: New → Confirmed
importance: Undecided → Medium
no longer affects: nova
Changed in openstack-api-site:
assignee: nobody → Diane Fleming (diane-fleming)
milestone: none → kilo
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to api-site (master)

Fix proposed to branch: master
Review: https://review.openstack.org/172761

Changed in openstack-api-site:
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to api-site (master)

Reviewed: https://review.openstack.org/172761
Committed: https://git.openstack.org/cgit/openstack/api-site/commit/?id=86b3d06d0e38134b88518cebf544af389a9c84df
Submitter: Jenkins
Branch: master

commit 86b3d06d0e38134b88518cebf544af389a9c84df
Author: Diane Fleming <email address hidden>
Date: Sun Apr 12 17:31:10 2015 -0500

    Update request parameters for os-interfaces extension

    Add return codes.

    Change-Id: I4693b20143e17927a04edf70de81a881c6d5f524
    Closes-Bug: #1352950

Changed in openstack-api-site:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

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