Deduplicate service status notification samples

This patch refactors the sample files of service-create, service-delete
and service-update notifications to use a common ServiceStatusPayload
sample data.

This patch addresses the problem which lead the revert of the commit
I708ce5423806d2913e77abbe338aec970a5009dc.

Change-Id: I2f619089ae88d05207bb3432c63546a298f0bf15
This commit is contained in:
Lajos Katona 2018-01-16 12:48:30 +01:00
parent d4377c2d53
commit ab937d8e7a
4 changed files with 26 additions and 44 deletions

View File

@ -0,0 +1,19 @@
{
"nova_object.name": "ServiceStatusPayload",
"nova_object.namespace": "nova",
"nova_object.version": "1.1",
"nova_object.data": {
"host": "host2",
"disabled": false,
"binary": "nova-compute",
"topic": "compute",
"disabled_reason": null,
"forced_down": false,
"version": 23,
"availability_zone": null,
"uuid": "fa69c544-906b-4a6a-a9c6-c1f7a8078c73",
"last_seen_up": null,
"report_count": 0
}
}

View File

@ -1,23 +1,9 @@
{
"priority": "INFO",
"payload": {
"nova_object.namespace": "nova",
"nova_object.name": "ServiceStatusPayload",
"nova_object.version": "1.1",
"nova_object.data": {
"host": "host2",
"disabled": false,
"last_seen_up": null,
"binary": "nova-compute",
"topic": "compute",
"disabled_reason": null,
"report_count": 0,
"forced_down": false,
"version": 23,
"availability_zone": null,
"uuid": "fa69c544-906b-4a6a-a9c6-c1f7a8078c73"
}
"$ref": "common_payloads/ServiceStatusPayload.json#"
},
"event_type": "service.create",
"publisher_id": "nova-compute:host2"
}

View File

@ -1,23 +1,9 @@
{
"priority": "INFO",
"payload": {
"nova_object.namespace": "nova",
"nova_object.name": "ServiceStatusPayload",
"nova_object.version": "1.1",
"nova_object.data": {
"host": "host2",
"disabled": false,
"last_seen_up": null,
"binary": "nova-compute",
"topic": "compute",
"disabled_reason": null,
"report_count": 0,
"forced_down": false,
"version": 23,
"availability_zone": null,
"uuid": "32887c0a-5063-4d39-826f-4903c241c376"
}
"$ref": "common_payloads/ServiceStatusPayload.json#"
},
"event_type": "service.delete",
"publisher_id": "nova-compute:host2"
}

View File

@ -1,23 +1,14 @@
{
"priority": "INFO",
"payload": {
"nova_object.namespace": "nova",
"nova_object.name": "ServiceStatusPayload",
"nova_object.version": "1.1",
"$ref": "common_payloads/ServiceStatusPayload.json#",
"nova_object.data": {
"host": "host1",
"disabled": false,
"last_seen_up": "2012-10-29T13:42:05Z",
"binary": "nova-compute",
"topic": "compute",
"disabled_reason": null,
"report_count": 1,
"forced_down": false,
"version": 23,
"availability_zone": null,
"uuid": "fa69c544-906b-4a6a-a9c6-c1f7a8078c73"
"report_count": 1
}
},
"event_type": "service.update",
"publisher_id": "nova-compute:host1"
}