[libvirt] [libvirt-python PATCH] implement new tunable event
Pavel Hrdina
phrdina at redhat.com
Tue Sep 30 17:24:42 UTC 2014
On 09/30/2014 06:49 PM, Eric Blake wrote:
> On 09/30/2014 10:00 AM, Pavel Hrdina wrote:
>> Resovles: https://bugzilla.redhat.com/show_bug.cgi?id=1147639
>
> s/Resovles/Resolves/
>
>>
>> Signed-off-by: Pavel Hrdina <phrdina at redhat.com>
>> ---
>> examples/event-test.py | 3 ++
>> libvirt-override-virConnect.py | 9 ++++++
>> libvirt-override.c | 64 ++++++++++++++++++++++++++++++++++++++++++
>> 3 files changed, 76 insertions(+)
>>
>> diff --git a/examples/event-test.py b/examples/event-test.py
>> index cd85de3..be7a7d4 100644
>> --- a/examples/event-test.py
>> +++ b/examples/event-test.py
>> @@ -515,6 +515,8 @@ def myDomainEventDeviceRemovedCallback(conn, dom, dev, opaque):
>> dom.name(), dom.ID(), dev))
>> def myDomainEventBlockJob2Callback(conn, dom, disk, type, status, opaque):
>> print("myDomainEventBlockJob2Callback: Domain %s(%s) %s on disk %s %s" % (dom.name(), dom.ID(), blockJobTypeToString(type), disk, blockJobStatusToString(status)))
>> +def myDomainEventTunableCallback(conn, dom, params, opaque):
>> + print("myDomainEventTunableCallback: Domain %s(%s) %s" % (dom.name(), dom.ID(), params))
>
> I wonder if we want any better control over the output formatting of
> params than what python defaults to, but this is probably okay for now.
>
>> +++ b/libvirt-override-virConnect.py
>> @@ -188,6 +188,15 @@
>> cb(self, virDomain(self, _obj=dom), devAlias, opaque)
>> return 0
>>
>> + def _dispatchDomainEventTunableCallback(self, dom, params, cbData):
>> + """Dispatches evetn to python user domain tunable event callbacks
>
> s/evetn/event/
>
> ACK with typos fixed.
>
Thanks, pushed with that typos fixed.
Pavel
More information about the libvir-list
mailing list