Commit 43921dda authored by Antoine Millet's avatar Antoine Millet
Browse files

Revert "Add a waiting loop in cold migration and clone"

This new feature is not yet implemented in cc-node.

This reverts commit 8bc10912.
parent 8be11fcf
Loading
Loading
Loading
Loading
+1 −10
Original line number Diff line number Diff line
@@ -185,16 +185,7 @@ class CloneJob(Job):
        watcher.register(source.conn, 'vol_export', pool, name, dest.ip, xferprop['port'])
        watcher.register(dest.conn, 'vol_import_wait', xferprop['id'])

        # Loop to poll status while job is running
        job_running = True
        while job_running:
            # Timeout to get transfered bytes and update status
            msgs = watcher.wait(timeout=10)
            if not msgs:
                _, percent = dest.proxy.vol_transfer_status(xferprop['id'])
                self.report('copy %s/%s: %d%% done' % (pool, name, percent))
            else:
                job_running = False
        msgs = watcher.wait()
        self._func_cancel_xfer = None

        # Compare checksum of two answers:
+1 −10
Original line number Diff line number Diff line
@@ -169,16 +169,7 @@ class ColdMigrationJob(Job):
        watcher.register(source.conn, 'vol_export', pool, name, dest.ip, xferprop['port'])
        watcher.register(dest.conn, 'vol_import_wait', xferprop['id'])

        # Loop to poll status while job is running
        job_running = True
        while job_running:
            # Timeout to get transfered bytes and update status
            msgs = watcher.wait(timeout=10)
            if not msgs:
                _, percent = dest.proxy.vol_transfer_status(xferprop['id'])
                self.report('copy %s/%s: %s%% done' % (pool, name, percent))
            else:
                job_running = False
        msgs = watcher.wait()
        self._func_cancel_xfer = None

        # Compare checksum of two answers: