Skip to content

PBM-1264 add timeout before the restore #158

PBM-1264 add timeout before the restore

PBM-1264 add timeout before the restore #158

GitHub Actions / JUnit Test Report failed Sep 3, 2024 in 0s

15 tests run, 13 passed, 1 skipped, 1 failed.

Annotations

Check failure on line 120 in pbm-functional/pytest/test_azurite.py

See this annotation in the file changed.

@github-actions github-actions / JUnit Test Report

test_azurite.test_incremental

AssertionError: Backup failed{"Error":"get backup metadata: get: context deadline exceeded"}
Raw output
start_cluster = True, cluster = <cluster.Cluster object at 0x7fd96b7fa610>

    @pytest.mark.timeout(300, func_only=True)
    def test_incremental(start_cluster, cluster):
        cluster.check_pbm_status()
>       cluster.make_backup("incremental --base")

test_azurite.py:120: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <cluster.Cluster object at 0x7fd96b7fa610>, type = 'incremental --base'

    def make_backup(self, type):
        n = testinfra.get_host("docker://" + self.pbm_cli)
        timeout = time.time() + 120
        while True:
            running = self.get_status()['running']
            Cluster.log("Current operation: " + str(running))
            if not running:
                if type:
                    start = n.run(
                        'pbm backup --out=json --type=' + type)
                else:
                    start = n.run('pbm backup --out=json')
                if start.rc == 0:
                    name = json.loads(start.stdout)['name']
                    Cluster.log("Backup started")
                    break
                elif "resync" in start.stdout:
                    Cluster.log("Resync in progress, retrying: " + start.stdout)
                else:
>                   assert False, "Backup failed" + start.stdout + start.stderr
E                   AssertionError: Backup failed{"Error":"get backup metadata: get: context deadline exceeded"}

cluster.py:392: AssertionError