Greetings! Unfortunately, I don't know the eventing context outside of ironic's ability to emit them, but I'll try my best to answer questions with my context. On Tue, Jul 7, 2020 at 1:02 AM Anil Jangam <anilj.mailing@gmail.com> wrote:
Hi All,
So far, based on my understanding of OpenStack Python SDK, I am able to read the Hypervisor, Servers instances, however, I do not see an API to receive and handle the change notification/events for the operations that happens on the cluster e.g. A new VM is added, an existing VM is deleted etc.
I see a documentation, which talks about emitting notifications over a message bus that indicate different events that occur within the service.
Notifications in OpenStack
https://docs.openstack.org/ironic/latest/admin/notifications.html
I suspect you may also find https://docs.openstack.org/nova/latest/reference/notifications.html useful.
Does Openstack Python SDK support notification APIs?
I'm going to guess the answer is no to this. As you noted earlier, the notifications are emitted to the message bus. These notifications can be read by a subscriber to the message bus itself, but this also means that the bus is directly connected to by some sort of messaging client. The Python SDK is intended for developers to use to leverage the REST APIs offered by services and components, not the message bus.
How do I receive/monitor notifications for VM related changes? How do I receive/monitor notifications for compute/hypervisor related changes? How do I receive/monitor notifications for Virtual Switch related changes?
I think what you are looking for is ceilometer. https://docs.openstack.org/ceilometer/latest/admin/telemetry-data-collection... Although that being said, I don't think much would really prevent you from consuming the notifications directly from the message bus, if you so desire. Maybe someone already has some code for this on hand.
Thanks in advance for any help in this regard.
Hope this helped.
/anil.
-Julia