We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d5f4946 commit 6968f15Copy full SHA for 6968f15
opentelemetry-sdk/src/opentelemetry/sdk/metrics/_internal/point.py
@@ -101,6 +101,18 @@ class ExponentialHistogram:
101
"opentelemetry.sdk.metrics.export.AggregationTemporality"
102
)
103
104
+ def to_json(self, indent=4) -> str:
105
+ return dumps(
106
+ {
107
+ "data_points": [
108
+ loads(data_point.to_json(indent=indent))
109
+ for data_point in self.data_points
110
+ ],
111
+ "aggregation_temporality": self.aggregation_temporality,
112
+ },
113
+ indent=indent,
114
+ )
115
+
116
117
@dataclass(frozen=True)
118
class Sum:
0 commit comments