Skip to content

Commit

Permalink
add sum to OTLP histogram
Browse files Browse the repository at this point in the history
Follow up to #2429.

Fixes #2430
  • Loading branch information
Alex Boten committed Feb 3, 2022
1 parent f237832 commit 3e2dd58
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,7 @@ def _translate_data(
time_unix_nano=metric.point.time_unix_nano,
start_time_unix_nano=metric.point.start_time_unix_nano,
count=sum(metric.point.bucket_counts),
sum=metric.point.sum,
bucket_counts=metric.point.bucket_counts,
explicit_bounds=metric.point.explicit_bounds,
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -589,6 +589,7 @@ def test_translate_histogram(self):
start_time_unix_nano=1641946016139533244,
time_unix_nano=1641946016139533244,
count=5,
sum=67,
bucket_counts=[1, 4],
explicit_bounds=[10.0, 20.0],
exemplars=[],
Expand Down

0 comments on commit 3e2dd58

Please sign in to comment.