Skip to content

Commit

Permalink
Retry on 'ch-backup list' for json error (#208)
Browse files Browse the repository at this point in the history
  • Loading branch information
kirillgarbar authored Jul 16, 2024
1 parent d2b6718 commit 6619922
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions ch_tools/common/backup.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@

import yaml

from ch_tools.common.clickhouse.client.retry import retry

CHS3_BACKUPS_DIRECTORY = "/var/lib/clickhouse/disks/object_storage/shadow/"


Expand Down Expand Up @@ -33,6 +35,7 @@ def load():
return BackupConfig(yaml.safe_load(file))


@retry(json.decoder.JSONDecodeError)
def get_backups() -> List[dict]:
"""
Get ClickHouse backups.
Expand Down

0 comments on commit 6619922

Please sign in to comment.