Change in vdsm[master]: asyncore: heartbeat fix
dkuznets at redhat.com
dkuznets at redhat.com
Mon Mar 23 09:32:44 UTC 2015
Dima Kuznetsov has posted comments on this change.
Change subject: asyncore: heartbeat fix
......................................................................
Patch Set 1:
(1 comment)
https://gerrit.ovirt.org/#/c/38988/1/lib/yajsonrpc/betterAsyncore.py
File lib/yajsonrpc/betterAsyncore.py:
Line 202:
Line 203: self._map.clear()
Line 204:
Line 205: def _get_timeout(self, map):
Line 206: timeout = 30.0
> None is problematic here. That is why we had to change it. Usually timeout
If there is no timeout you can do something like this:
timeout = {}
....
timeout['timeout'] = min(interval, timeout['timeout'])
....
asyncore.loop(..., **timeout)
Might be a bit ugly so it is your call
Line 207: for disp in self._map.values():
Line 208: if hasattr(disp, "next_check_interval"):
Line 209: interval = disp.next_check_interval()
Line 210: if interval is not None and interval >= 0:
--
To view, visit https://gerrit.ovirt.org/38988
To unsubscribe, visit https://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: Icad61fb62509764e8ecdd6f87ef60557f4465368
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Piotr Kliczewski <piotr.kliczewski at gmail.com>
Gerrit-Reviewer: Dima Kuznetsov <dkuznets at redhat.com>
Gerrit-Reviewer: Francesco Romani <fromani at redhat.com>
Gerrit-Reviewer: Piotr Kliczewski <piotr.kliczewski at gmail.com>
Gerrit-Reviewer: Saggi Mizrahi <smizrahi at redhat.com>
Gerrit-Reviewer: Yaniv Bronhaim <ybronhei at redhat.com>
Gerrit-Reviewer: Yeela Kaplan <ykaplan at redhat.com>
Gerrit-Reviewer: automation at ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
More information about the vdsm-patches
mailing list