Jump to: navigation, search

Nova/ExternalEventAPI

< Nova
Revision as of 19:40, 19 February 2014 by Dan Smith (talk | contribs) (Created page with "== Use-cases == # Neutron needs to notify Nova that a new floating IP has been allocated to an instance. Neutron sends an event of "network-changed" to Nova for the affected ...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Use-cases

  1. Neutron needs to notify Nova that a new floating IP has been allocated to an instance. Neutron sends an event of "network-changed" to Nova for the affected instance. Nova then refreshes the Instance's info_cache from neutron.
  2. Nova is booting a guest and asks Neutron to plumb the VIFs. It makes that request and then blocks the boot while waiting for the callback from Neutron. When Neutron has completed, it sends an event of type "vif-plugged" with the tag set to the port_id of the relevant VIF for the affected instance. When all of the vif-plugged events have been received, Nova continues the boot process.
  3. Nova needs Cinder to do a coordinated snapshot of a volume. Nova asks Cinder to do this and then blocks. When Cinder has completed, it sends an event of volume-snapshotted with the tag set to the volume_id for the affected Instance. Nova then unblocks the snapshotting process and continues.

API Sample

To send the "test-event" with tag "foo" to a server, POST to /os-server-external-events something like:

{
 "event": {
   "name": "test-event",
   "tag": "foo",
   "server_uuid": "71b20737-7f90-4513-abde-4a2dfd8ae97e"
   }
}