Skip to content

Commit 698a95f

Browse files
committed
Rename BatteryPool.AggregateMethod to MetricAggregator
Signed-off-by: Sahas Subramanian <[email protected]>
1 parent 16a677b commit 698a95f

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/frequenz/sdk/timeseries/battery_pool/_methods.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
_logger = logging.getLogger(__name__)
2626

2727

28-
class AggregateMethod(Generic[T], ABC):
28+
class MetricAggregator(Generic[T], ABC):
2929
"""Interface to control how the component data should be aggregated and send."""
3030

3131
@abstractmethod
@@ -61,7 +61,7 @@ def name(cls) -> str:
6161
"""
6262

6363

64-
class SendOnUpdate(AggregateMethod[T]):
64+
class SendOnUpdate(MetricAggregator[T]):
6565
"""Wait for the change of the components metrics and send updated result.
6666
6767
This method will cache the component metrics. When any metric change it will

src/frequenz/sdk/timeseries/battery_pool/battery_pool.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
FormulaGeneratorConfig,
2626
FormulaType,
2727
)
28-
from ._methods import AggregateMethod, SendOnUpdate
28+
from ._methods import MetricAggregator, SendOnUpdate
2929
from ._metric_calculator import CapacityCalculator, PowerBoundsCalculator, SoCCalculator
3030
from ._result_types import CapacityMetrics, PowerMetrics, SoCMetrics
3131

@@ -85,7 +85,7 @@ def __init__( # pylint: disable=too-many-arguments
8585
)
8686

8787
self._min_update_interval = min_update_interval
88-
self._active_methods: dict[str, AggregateMethod[Any]] = {}
88+
self._active_methods: dict[str, MetricAggregator[Any]] = {}
8989

9090
self._namespace: str = f"battery-pool-{self._batteries}-{uuid.uuid4()}"
9191
self._formula_pool: FormulaEnginePool = FormulaEnginePool(

0 commit comments

Comments
 (0)