Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
greyfenrir committed Mar 9, 2022
1 parent 6a40839 commit 001f6e5
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions bzt/modules/aggregator.py
Original file line number Diff line number Diff line change
Expand Up @@ -665,7 +665,9 @@ def datapoints(self, final_pass=False):
"""
for datapoint in self._calculate_datapoints(final_pass):
current = datapoint[DataPoint.CURRENT]
if datapoint[DataPoint.CUMULATIVE] or not self._ramp_up_exclude():

exclude_as_ramp_up = self._ramp_up_exclude() and not datapoint[DataPoint.CUMULATIVE]
if not exclude_as_ramp_up:
self.__merge_to_cumulative(current)
datapoint[DataPoint.CUMULATIVE] = copy.deepcopy(self.cumulative)
datapoint.recalculate()
Expand Down Expand Up @@ -888,7 +890,7 @@ def __init__(self):
self.buffer = {}
self.histogram_max = 5.0
self._sticky_concurrencies = {}
self.min_timestamp = None
self.min_timestamp = None # first aggregated data timestamp, just for exclude_ramp_up feature

def converter(self, data):
if data and self._redundant_aggregation:
Expand Down Expand Up @@ -1075,6 +1077,7 @@ def _calculate_datapoints(self, final_pass=False):

if subresult['ts'] < self.min_timestamp + self._get_max_ramp_up():
subresult[DataPoint.CUMULATIVE] = dict()
# cleaning cumulative value is used as 'exclude ramp-up still' flag

Concurrency.update_sticky(self._sticky_concurrencies, points_to_consolidate)
point = points_to_consolidate[0]
Expand Down

0 comments on commit 001f6e5

Please sign in to comment.