while with newer oslo.serialization it looks like:
'reason': "NoValidHost(u'No valid host was found. ',)",
So the oslo.serialization change did affect the payload of the legacy compute_task.build_instances ERROR notification.
Please note that this notification hasn't been transformed to the new versioned framework yet. But this bug does not directly affect any already transformed notification as the Exception payload in the versioned notifications does not directly store a serialized Exception object. Instead it contains just the exception type and the exception message.
So with oslo.serialization 2.21.1 the reason field of the compute_ task.build_ instances legacy notification looks like:
'reason': {'kwargs': {'code': 500, 'reason': ''},
'message' : u'No valid host was found. '},
while with newer oslo.serialization it looks like:
'reason': "NoValidHost(u'No valid host was found. ',)",
So the oslo.serialization change did affect the payload of the legacy compute_ task.build_ instances ERROR notification.
Please note that this notification hasn't been transformed to the new versioned framework yet. But this bug does not directly affect any already transformed notification as the Exception payload in the versioned notifications does not directly store a serialized Exception object. Instead it contains just the exception type and the exception message.
https:/ /github. com/openstack/ nova/blob/ master/ nova/notificati ons/objects/ exception. py#L25 /github. com/openstack/ nova/blob/ master/ doc/notificatio n_samples/ instance- create- error.json
https:/
---
See the full payload below:
{'instance_id': 'c1168eba- 89a1-43af- 86bd-b6c164dd0f 94', properties' : {'availability_ zone': None,
'ephemeral_ gb': 0,
'memory_ mb': 512,
'numa_ topology' : None,
'pci_ requests' : {'requests': []},
'project_ id': u'6f70656e73746 1636b2034206576 6572',
'root_ gb': 1,
'uuid' : 'c1168eba- 89a1-43af- 86bd-b6c164dd0f 94',
'vcpus' : 1},
'message' : u'No valid host was found. '}, format' : u'raw',
'created_ at': '2011-01- 01T01:02: 03.000000' ,
'disk_format' : u'raw',
'id': '155d900f- 4e14-4e4c- a73d-069cbf4541 e6',
'name': u'fakeimage123456',
'properties' : {'hw_architecture': u'x86_64'},
'size': 25165824,
'status' : u'active',
'updated_ at': '2011-01- 01T01:02: 03.000000' },
'instance_ properties' : {'availability_ zone': None,
'ephemeral_ gb': 0,
'memory_ mb': 512,
'numa_topology' : None,
'pci_requests' : {'requests': []},
'project_ id': u'6f70656e73746 1636b2034206576 6572',
'root_gb' : 1,
'uuid': 'c1168eba- 89a1-43af- 86bd-b6c164dd0f 94',
'vcpus' : 1},
'instance_ type': {'created_at': '2018-03- 26T13:05: 22.000000' ,
'deleted' : False,
'deleted_ at': None,
'description' : None,
'disabled' : False,
'ephemeral_ gb': 0,
'extra_ specs': {},
'flavorid' : u'1',
'id': 1,
'is_public' : True,
'memory_ mb': 512,
'name' : u'm1.tiny',
'root_ gb': 1,
'rxtx_ factor' : 1.0,
'swap' : 0,
'updated_ at': None,
'vcpu_ weight' : 0,
'vcpus' : 1},
'num_ instances' : 1},
'instance_
'method': 'build_instances',
'reason': {'kwargs': {'code': 500, 'reason': ''},
'request_spec': {'image': {'container_
'state': 'error'}
---
{'instance_id': 'd0c8163c- 3050-4dd7- a7cf-66f03719d3 b9', properties' : {'availability_ zone': None,
'ephemeral_ gb': 0,
'memory_ mb': 512,
'numa_ topology' : None,
'pci_requests' : {'requests': []},
'project_ id': u'6f70656e73746 1636b2034206576 6572',
'root_ gb': 1,
'uuid' : 'd0c8163c- 3050-4dd7- a7cf-66f03719d3 b9',
'vcpus' : 1}, spec': {'image': {'container_ format' : u'raw',
'created_ at': '2011-01- 01T01:02: 03.000000' ,
'disk_ format' : u'raw',
'id' : '155d900f- 4e14-4e4c- a73d-069cbf4541 e6',
'name' : u'fakeimage123456',
'properties ': {'hw_architecture': u'x86_64'},
'size' : 25165824,
'status' : u'active',
'updated_ at': '2011-01- 01T01:02: 03.000000' },
'instance_ properties' : {'availability_ zone': None,
'ephemeral_ gb': 0,
'memory_ mb': 512,
'numa_ topology' : None,
'pci_ requests' : {'requests': []},
'project_ id': u'6f70656e73746 1636b2034206576 6572',
'root_ gb': 1,
'uuid' : 'd0c8163c- 3050-4dd7- a7cf-66f03719d3 b9',
'vcpus' : 1},
'instance_ type': {'created_at': '2018-03- 26T13:02: 12.000000' ,
'deleted' : False,
'deleted_ at': None,
'descripti on': None,
'disabled' : False,
'ephemeral _gb': 0,
'extra_ specs': {},
'flavorid' : u'1',
'id' : 1,
'is_ public' : True,
'memory_ mb': 512,
'name' : u'm1.tiny',
'root_ gb': 1,
'rxtx_ factor' : 1.0,
'swap' : 0,
'updated_ at': None,
'vcpu_ weight' : 0,
'vcpus' : 1},
'num_instances ': 1},
'instance_
'method': 'build_instances',
'reason': "NoValidHost(u'No valid host was found. ',)",
'request_
'state': 'error'}