2 Commits

Author SHA1 Message Date
Balazs Gibizer
05adc8d006 Generate doc for versioned notifications
This commit adds a new sphinx extension that inspects the nova code
and adds information about the existing versioned notifications to
the nofitications devref. This way the devref is automatically kept
up to date with relevant information.

Partially-Implements: bp versioned-notification-api
Change-Id: If65d5d81e26cb2b4a9f57a8c7d37d3de310ebe00
2016-01-28 15:33:06 +01:00
Balazs Gibizer
33c3f61c92 Add service status notification
When the status of the Service object is changed
nova will send a new service.update notification
with versioned payload according to bp versioned-notification-api

For example
  nova service-disable --reason 'my reason' controller nova-compute
will generate the following notification
{
    "priority":"INFO",
    "event_type":"service.update",
    "timestamp":"2015-11-13 11:12:04.211575",
    "publisher_id":"nova-compute:controller",
    "payload":{
        "nova_object.version":"1.0",
        "nova_object.name":"ServiceStatusPayload",
        "nova_object.namespace":"nova",
        "nova_object.data":{
            "binary":"nova-compute",
            "report_count":1,
            "topic":"compute",
            "host":"controller",
            "version":2,
            "disabled":true,
            "forced_down":false,
            "last_seen_up":"2015-11-12T13:46:25Z",
            "disabled_reason":"my reason",
        }
    },
    "message_id":"8516b5c7-c6a7-43a4-9ad1-df447f318afb"
}

Implements: bp service-status-notification
Change-Id: I82f1935eaf55220bf261d8b8240fd35d822c9404
2016-01-20 15:31:55 +01:00