The monitor uses the PropertyCollector API to detect changes in the MAC addresses of VMs. The PropertyCollector is initialized with a ContainerView of all VMs. As we can observe MAC addresses either from the virtual ethernet cards or through the guest the property spec includes all VM virtual devices - config.hardware.device and guest networks - guest.net. As ethernet cards are only one of many possible virtual devices, we will receive spurious updates related to other hardware. Also DHCP changes will update the guest.net values even when the MAC and IP addresses do not change. To mitigate the spurious updates the property collector output is filtered through a cache of currently known values that only lets through real changes to MAC and IP addresses.
The code can be enhanced to run in a background executor and provide query capability to query the cache as necessary.
This change also fixes the suds dependency for python 3.
The monitor uses the
PropertyCollector
API to detect changes in the MAC addresses of VMs. ThePropertyCollector
is initialized with aContainerView
of all VMs. As we can observe MAC addresses either from the virtual ethernet cards or through the guest the property spec includes all VM virtual devices -config.hardware.device
and guest networks -guest.net
. As ethernet cards are only one of many possible virtual devices, we will receive spurious updates related to other hardware. Also DHCP changes will update theguest.net
values even when the MAC and IP addresses do not change. To mitigate the spurious updates the property collector output is filtered through a cache of currently known values that only lets through real changes to MAC and IP addresses.The code can be enhanced to run in a background executor and provide query capability to query the cache as necessary.
This change also fixes the
suds
dependency for python 3.