emit notifications on notifications_designate
Change I804a34fb044090010ecfd2560594cc1f55e9bd21, commit hash
b89de21d47
dropped notifications_designate
completely to solve a problem described in pad.lv/1738100, however, to
make this change backwards compatible notifications_designate should be
used in addition to "notifications" topic used by default.
This way designate will continue to receive notifications on
notifications_designate from nova, and ceilometer will get notifications
using the "notifications" topic.
Change-Id: I245f5b263994c204a5e521dad542ed83952f54b8
Related-Bug: #1710831
Related-Bug: #1738100
This commit is contained in:
parent
f4f195253a
commit
6b9b02c112
|
@ -598,6 +598,9 @@ class DesignateContext(context.OSContextGenerator):
|
|||
if related_units(rid):
|
||||
ctxt['enable_designate'] = True
|
||||
if ctxt['enable_designate']:
|
||||
notification_topics = ['notifications',
|
||||
'notifications_designate']
|
||||
ctxt['notification_topics'] = ','.join(notification_topics)
|
||||
ctxt['notify_on_state_change'] = 'vm_and_task_state'
|
||||
return ctxt
|
||||
|
||||
|
|
|
@ -517,6 +517,7 @@ class DesignateContextTests(CharmTestCase):
|
|||
self.related_units.return_value = 'designate/0'
|
||||
self.assertEqual(designatectxt(), {
|
||||
'enable_designate': True,
|
||||
'notification_topics': 'notifications,notifications_designate',
|
||||
'notify_on_state_change': 'vm_and_task_state',
|
||||
})
|
||||
|
||||
|
|
Loading…
Reference in New Issue