From 387837a463a540301728435c684b0a030b239ffd Mon Sep 17 00:00:00 2001 From: Stefaan Lippens Date: Fri, 1 Mar 2024 18:04:36 +0100 Subject: [PATCH] Issue #112 remove `AggregatorConfig.partitioned_job_tracking` replaced by `AggregatorBackendConfig.partitioned_job_tracking` --- src/openeo_aggregator/backend.py | 2 +- src/openeo_aggregator/config.py | 3 --- src/openeo_aggregator/partitionedjobs/zookeeper.py | 2 +- 3 files changed, 2 insertions(+), 5 deletions(-) diff --git a/src/openeo_aggregator/backend.py b/src/openeo_aggregator/backend.py index 4df1265..21d4a9e 100644 --- a/src/openeo_aggregator/backend.py +++ b/src/openeo_aggregator/backend.py @@ -1295,7 +1295,7 @@ def __init__(self, backends: MultiBackendConnection, config: AggregatorConfig): config=config, ) - if get_backend_config().partitioned_job_tracking or config.partitioned_job_tracking: + if get_backend_config().partitioned_job_tracking: partitioned_job_tracker = PartitionedJobTracker.from_config(config=config, backends=self._backends) else: partitioned_job_tracker = None diff --git a/src/openeo_aggregator/config.py b/src/openeo_aggregator/config.py index 4cc50a5..b1733d4 100644 --- a/src/openeo_aggregator/config.py +++ b/src/openeo_aggregator/config.py @@ -42,9 +42,6 @@ class AggregatorConfig(dict): config_source = dict_item() - # TODO #112 deprecated, instead use AggregatorBackendConfig.partitioned_job_tracking - partitioned_job_tracking = dict_item(default=None) - # TODO #112 Deprecated, use AggregatorBackendConfig.zookeeper_prefix instead zookeeper_prefix = dict_item(default="/openeo-aggregator/") diff --git a/src/openeo_aggregator/partitionedjobs/zookeeper.py b/src/openeo_aggregator/partitionedjobs/zookeeper.py index 8397f72..e6d43e6 100644 --- a/src/openeo_aggregator/partitionedjobs/zookeeper.py +++ b/src/openeo_aggregator/partitionedjobs/zookeeper.py @@ -43,7 +43,7 @@ def __init__(self, client: KazooClient, prefix: str = None): @classmethod def from_config(cls, config: AggregatorConfig) -> "ZooKeeperPartitionedJobDB": # Get ZooKeeper client - pjt_config = get_backend_config().partitioned_job_tracking or config.partitioned_job_tracking + pjt_config = get_backend_config().partitioned_job_tracking if pjt_config.get("zk_client"): zk_client = pjt_config["zk_client"] elif pjt_config.get("zk_hosts"):