From acb9e94d91f412a0ffc7c6aac4ceb58dff8efc6b Mon Sep 17 00:00:00 2001 From: Finn Roblin Date: Mon, 22 Jul 2024 11:11:54 -0700 Subject: [PATCH] Add TODO to support more levels of nesting in the future Signed-off-by: Finn Roblin --- osbenchmark/workload/params.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/osbenchmark/workload/params.py b/osbenchmark/workload/params.py index e91e0e96d..24c68466b 100644 --- a/osbenchmark/workload/params.py +++ b/osbenchmark/workload/params.py @@ -983,9 +983,12 @@ def partition(self, partition_index, total_partitions): def get_split_fields(self) -> Tuple[str, str]: fields_as_array = self.field_name.split(self.NESTED_FIELD_SEPARATOR) + + # TODO: Add support to multiple levels of nesting if a future benchmark requires it. + if len(fields_as_array) != 2: raise ValueError( - f"Field name {self.field_name} is not a nested field name" + f"Field name {self.field_name} is not a nested field name. Currently we support only 1 level of nesting." ) return fields_as_array[0], fields_as_array[1]