Adapt otel exponential histogram data#10449
Conversation
|
Please build a test case for the convert, as |
...org/apache/skywalking/oap/server/receiver/otel/otlp/OpenTelemetryMetricRequestProcessor.java
Show resolved
Hide resolved
Ok, I get it. I will add the test case into the test dir. I think I need some time to learn how to build my test case because it is different from the plugin-test which I done before. |
|
We just need a unit test. What is in the test folder(root) is e2e testing. |
...org/apache/skywalking/oap/server/receiver/otel/otlp/OpenTelemetryMetricRequestProcessor.java
Outdated
Show resolved
Hide resolved
...org/apache/skywalking/oap/server/receiver/otel/otlp/OpenTelemetryMetricRequestProcessor.java
Show resolved
Hide resolved
…n/java/org/apache/skywalking/oap/server/receiver/otel/otlp/OpenTelemetryMetricRequestProcessor.java Co-authored-by: kezhenxu94 <kezhenxu94@apache.org>
...org/apache/skywalking/oap/server/receiver/otel/otlp/OpenTelemetryMetricRequestProcessor.java
Outdated
Show resolved
Hide resolved
|
@mufiye One question, does this histogram always build bucket boundaries as integers? Could it be a very small double? Because when we calculate percentile from the histogram (usually we do today), the values are bucket boundaries and they should be integer/long only. |
This histogram always builds bucket boundaries as double. I don't fully understand what you mean. |
...apache/skywalking/oap/server/receiver/otel/otlp/OpenTelemetryMetricRequestProcessorTest.java
Outdated
Show resolved
Hide resolved
...org/apache/skywalking/oap/server/receiver/otel/otlp/OpenTelemetryMetricRequestProcessor.java
Show resolved
Hide resolved
Check hisgram percentile function, which calculate the value. The percentile value is the rank of the bucket. |
|
Check how |
I have understood this question. I think the small double case maybe happen. But this case also maybe happen for otel histogram data. |
...org/apache/skywalking/oap/server/receiver/otel/otlp/OpenTelemetryMetricRequestProcessor.java
Show resolved
Hide resolved
If current, the buckets of airflow definition are good, we should be fine. Otherwise, we may need some closure to process the buckets, such as maybe, we need multiple 1000 from microsecond to millisecond precision. |
I review the data collected from airflow and find there are some small timer data, such as 1.182709 and 1.348083 in one exponentialHistogram data. Where should I add the closure? |
When you write MAL. |
I read other services' otel rule cases and meter analysis language but have no idea how to do this. Could you explain it more? |
There is no other for these. Because they don't use small doubles as buckets. If you want to learn this for now, then MAL is groovy based script. |
I think I need to fully understand the meter analyzer code first if I want to add this function. In my current opinion, the function can not be put into the |
Yes, it should be on the MAL(SampleFamily) part. |
...org/apache/skywalking/oap/server/receiver/otel/otlp/OpenTelemetryMetricRequestProcessor.java
Outdated
Show resolved
Hide resolved
…n/java/org/apache/skywalking/oap/server/receiver/otel/otlp/OpenTelemetryMetricRequestProcessor.java
wu-sheng
left a comment
There was a problem hiding this comment.
LGTM @kezhenxu94 @wankai123 Please take another look.
...org/apache/skywalking/oap/server/receiver/otel/otlp/OpenTelemetryMetricRequestProcessor.java
Outdated
Show resolved
Hide resolved
...org/apache/skywalking/oap/server/receiver/otel/otlp/OpenTelemetryMetricRequestProcessor.java
Outdated
Show resolved
Hide resolved
...apache/skywalking/oap/server/receiver/otel/otlp/OpenTelemetryMetricRequestProcessorTest.java
Outdated
Show resolved
Hide resolved
...apache/skywalking/oap/server/receiver/otel/otlp/OpenTelemetryMetricRequestProcessorTest.java
Outdated
Show resolved
Hide resolved
...apache/skywalking/oap/server/receiver/otel/otlp/OpenTelemetryMetricRequestProcessorTest.java
Outdated
Show resolved
Hide resolved
...apache/skywalking/oap/server/receiver/otel/otlp/OpenTelemetryMetricRequestProcessorTest.java
Outdated
Show resolved
Hide resolved
…t/java/org/apache/skywalking/oap/server/receiver/otel/otlp/OpenTelemetryMetricRequestProcessorTest.java Co-authored-by: kezhenxu94 <kezhenxu94@apache.org>
…t/java/org/apache/skywalking/oap/server/receiver/otel/otlp/OpenTelemetryMetricRequestProcessorTest.java Co-authored-by: kezhenxu94 <kezhenxu94@apache.org>
I find the
OpenTelemetryMetricRequestProcessor#adaptMetricsin otel-receiver-plugin can not process exponential histogram metric. But some service will use this exponentialHistogram instead of histogram metric, such as statsd receiver in opentelemetry collector. So I do this pull request to adapt this case.The related discussion about this pull request is in issue #10341.
If this is non-trivial feature, paste the links/URLs to the design doc.
Update the documentation to include this new feature.
Tests(including UT, IT, E2E) are added to verify the new feature.
If it's UI related, attach the screenshots below.
If this pull request closes/resolves/fixes an existing issue, replace the issue number. Closes #.
Update the
CHANGESlog.