OS API should implement network association

Registered by Alexej Ababilov

Nowadays networks are associated with projects automatically during launch of an instance. The network is chosen rather randomly.
OS API should support association of given network and project.

URI: v1.1/{tenant_id}/os-networks/add
Method: POST
Body: {
    "id": "<network UUID or None>"
}
Response body: empty
Response code: 202

If the given network UUID is None, a random free network will be chosen.

Sample request:
curl -X 'POST' 'http://main-node:8774/v1.1/45d2e66674b647c2bee1d1f18ae64e93/os-networks/add -H 'Content-Type: application/json' -H 'X-Auth-Token: b4be16290db84726bc71d10f0947aa13' -d '{"id": "44b6f3d2-ed5f-4711-b2fa-96e29cf13ac0"}'

Blueprint information

Status:
Complete
Approver:
Vish Ishaya
Priority:
Low
Drafter:
None
Direction:
Needs approval
Assignee:
Alexej Ababilov
Definition:
Approved
Series goal:
Accepted for folsom
Implementation:
Implemented
Milestone target:
milestone icon 2012.2
Started by
Vish Ishaya
Completed by
Thierry Carrez

Related branches

Sprints

Whiteboard

Gerrit topic: https://review.openstack.org/#q,topic:bp/os-api-network-associate,n,z

Addressed by: https://review.openstack.org/9852
    implement network association in OS API

(?)

Work Items

This blueprint contains Public information 
Everyone can see this information.