From: Dirk Mueller Date: Mon, 14 Apr 2014 15:12:23 +0000 (+0200) Subject: Switch over to FixedIntervalLoopingCall X-Git-Url: https://review.fuel-infra.org/gitweb?a=commitdiff_plain;h=0814bff9366974d77d42d03fa11f60fbe469a8c7;p=openstack-build%2Fcinder-build.git Switch over to FixedIntervalLoopingCall Change-Id: Iebe5269ea01acdd4ba011742831ca5e569f66b28 Closes-Bug: #1307560 --- diff --git a/cinder/service.py b/cinder/service.py index 811a6c8cf..7d0d57171 100755 --- a/cinder/service.py +++ b/cinder/service.py @@ -119,7 +119,8 @@ class Service(service.Service): self.rpcserver.start() if self.report_interval: - pulse = loopingcall.LoopingCall(self.report_state) + pulse = loopingcall.FixedIntervalLoopingCall( + self.report_state) pulse.start(interval=self.report_interval, initial_delay=self.report_interval) self.timers.append(pulse) @@ -130,7 +131,8 @@ class Service(service.Service): else: initial_delay = None - periodic = loopingcall.LoopingCall(self.periodic_tasks) + periodic = loopingcall.FixedIntervalLoopingCall( + self.periodic_tasks) periodic.start(interval=self.periodic_interval, initial_delay=initial_delay) self.timers.append(periodic) diff --git a/cinder/volume/drivers/ibm/storwize_svc/__init__.py b/cinder/volume/drivers/ibm/storwize_svc/__init__.py index eb0f58955..6f6cee27c 100644 --- a/cinder/volume/drivers/ibm/storwize_svc/__init__.py +++ b/cinder/volume/drivers/ibm/storwize_svc/__init__.py @@ -207,7 +207,7 @@ class StorwizeSVCDriver(san.SanDriver): # if vdiskcopy exists in database, start the looping call if len(self._vdiskcopyops) >= 1: - self._vdiskcopyops_loop = loopingcall.LoopingCall( + self._vdiskcopyops_loop = loopingcall.FixedIntervalLoopingCall( self._check_volume_copy_ops) self._vdiskcopyops_loop.start(interval=self.VDISKCOPYOPS_INTERVAL) @@ -567,7 +567,7 @@ class StorwizeSVCDriver(san.SanDriver): # We added the first copy operation, so start the looping call if len(self._vdiskcopyops) == 1: - self._vdiskcopyops_loop = loopingcall.LoopingCall( + self._vdiskcopyops_loop = loopingcall.FixedIntervalLoopingCall( self._check_volume_copy_ops) self._vdiskcopyops_loop.start(interval=self.VDISKCOPYOPS_INTERVAL)