Francesco Romani has posted comments on this change.
Change subject: sampling: HostStatsThread as periodic operation
......................................................................
Patch Set 5:
(4 comments)
https://gerrit.ovirt.org/#/c/40431/5//COMMIT_MSG
Commit Message:
Line 6:
Line 7: sampling: HostStatsThread as periodic operation
Line 8:
Line 9: This patch extracts the actual host sampling code
Line 10: from HostStatsThread into a new helper class, HostSampler,
s/HostSampler/HostMonitor
Done
Line 11: which is made conform to the Task/Periodic interface.
Line 12:
Line 13: The new HostSampler code is moved under the periodic
Line 14: infrastructure. Finally, HostStatsThread is removed.
https://gerrit.ovirt.org/#/c/40431/5/lib/vdsm/config.py.in
File lib/vdsm/config.py.in:
Line 317:
Line 318: # Section: [sampling]
Line 319: ('sampling', [
Line 320:
Line 321: ('periodic_workers', '5',
explain why, or drop this change
Will be moved to a later
patch.
Line 322: 'Number of worker threads to serve the periodic tasks.'
Line 323: ' This is for internal usage and may change without
warning'),
Line 324:
Line 325: ('periodic_task_per_worker', '100',
https://gerrit.ovirt.org/#/c/40431/5/vdsm/virt/periodic.py
File vdsm/virt/periodic.py:
Line 104: config.getint('vars', 'vm_watermark_interval')),
Line 105:
Line 106: Operation(
Line 107: sampling.HostMonitor(
Line 108: cif.log),
no need to have cif.log on a new line
Done
Line 109: config.getint('vars',
'host_sample_stats_interval'))
Line 110:
Line 111: ]
Line 112:
https://gerrit.ovirt.org/#/c/40431/5/vdsm/virt/sampling.py
File vdsm/virt/sampling.py:
Line 543: return doms
Line 544:
Line 545:
Line 546: class HostMonitor(object):
Line 547: _connlog = logging.getlogger('connectivity')
why rename? Bad vim keystroke? :\
Done
Line 548:
Line 549: def __init__(self, log):
Line 550: self._log = log
Line 551: self._start_time = time.time()
--
To view, visit
https://gerrit.ovirt.org/40431
To unsubscribe, visit
https://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I39c2e6e4bca286a513992b7231f1356e8dd871a1
Gerrit-PatchSet: 5
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Francesco Romani <fromani(a)redhat.com>
Gerrit-Reviewer: Francesco Romani <fromani(a)redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: automation(a)ovirt.org
Gerrit-HasComments: Yes