Change in vdsm[ovirt-3.5]: clientIF: Use a weakref.proxy when registering contEIOVMs

danken at redhat.com danken at redhat.com
Tue Dec 2 21:07:04 UTC 2014


Dan Kenigsberg has submitted this change and it was merged.

Change subject: clientIF: Use a weakref.proxy when registering contEIOVMs
......................................................................


clientIF: Use a weakref.proxy when registering contEIOVMs

Our storage Event class is taking a weakref on the callback function
that is passed into Event.register.  Unfortunately weakrefs on bound
methods are dead on arrival.  See this [1] discussion for more
information.  Use the same approach as StoragePool._upgradeCallback and
use a weakref.proxy to build the callback function.

[1] http://code.activestate.com/recipes/81253/

Change-Id: Ib06967b26fc9ace41e5f8305a8fadafbbb0fc4e4
Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1157421
Signed-off-by: Adam Litke <alitke at redhat.com>
Reviewed-on: http://gerrit.ovirt.org/35436
Reviewed-by: Nir Soffer <nsoffer at redhat.com>
Reviewed-by: Dan Kenigsberg <danken at redhat.com>
Reviewed-on: http://gerrit.ovirt.org/35808
---
M vdsm/clientIF.py
1 file changed, 4 insertions(+), 1 deletion(-)

Approvals:
  Adam Litke: Verified
  Dan Kenigsberg: Looks good to me, approved



-- 
To view, visit http://gerrit.ovirt.org/35808
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ib06967b26fc9ace41e5f8305a8fadafbbb0fc4e4
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: ovirt-3.5
Gerrit-Owner: Adam Litke <alitke at redhat.com>
Gerrit-Reviewer: Adam Litke <alitke at redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Doron Fediuck <dfediuck at redhat.com>
Gerrit-Reviewer: Nir Soffer <nsoffer at redhat.com>
Gerrit-Reviewer: automation at ovirt.org


More information about the vdsm-patches mailing list