Change in vdsm[master]: multipath: Replace timing code with utils.stopwatch

danken at redhat.com danken at redhat.com
Fri Jul 24 22:28:01 UTC 2015


Dan Kenigsberg has submitted this change and it was merged.

Change subject: multipath: Replace timing code with utils.stopwatch
......................................................................


multipath: Replace timing code with utils.stopwatch

The old timing code was longer then the code it measured, and it was
issuing 2 syscalls even if debug log was not enabled. Using the
stopwatch contextmanager, we need only one line of code, and we measure
the time only if we need to log it.

Change-Id: Ic9ae9c4f7b9e10ef07f1c9a8e8bce9aaf042d9af
Signed-off-by: Nir Soffer <nsoffer at redhat.com>
Reviewed-on: https://gerrit.ovirt.org/42566
Continuous-Integration: Jenkins CI
Reviewed-by: Freddy Rolland <frolland at redhat.com>
Reviewed-by: Dan Kenigsberg <danken at redhat.com>
---
M vdsm/storage/multipath.py
1 file changed, 8 insertions(+), 10 deletions(-)

Approvals:
  Nir Soffer: Verified
  Jenkins CI: Passed CI tests
  Dan Kenigsberg: Looks good to me, approved
  Freddy Rolland: Looks good to me, but someone else must approve



-- 
To view, visit https://gerrit.ovirt.org/42566
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ic9ae9c4f7b9e10ef07f1c9a8e8bce9aaf042d9af
Gerrit-PatchSet: 5
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer <nsoffer at redhat.com>
Gerrit-Reviewer: Adam Litke <alitke at redhat.com>
Gerrit-Reviewer: Ala Hino <ahino at redhat.com>
Gerrit-Reviewer: Allon Mureinik <amureini at redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Federico Simoncelli <fsimonce at redhat.com>
Gerrit-Reviewer: Francesco Romani <fromani at redhat.com>
Gerrit-Reviewer: Freddy Rolland <frolland at redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer <nsoffer at redhat.com>
Gerrit-Reviewer: Yaniv Bronhaim <ybronhei at redhat.com>
Gerrit-Reviewer: automation at ovirt.org


More information about the vdsm-patches mailing list