Hi Prometheus,
This is Yang from OpenCensus. Last year we added an OpenCensus Prometheus exporter that exports metrics to Prometheus end points. I saw you added an optional "timestamp" value as part of metric sample in #337 - on OpenCensus we haven't updated our exporter to set this field. However, when our users were using the OpenCensus Prometheus exporter, they got a bunch of warning logs saying (original issue: census-instrumentation/opencensus-java#1215):
[WARNING]
java.lang.NoSuchFieldError: timestampMs
at io.prometheus.client.exporter.common.TextFormat.write004 (TextFormat.java:49)
at io.prometheus.client.exporter.HTTPServer$HTTPMetricHandler.handle (HTTPServer.java:59)
at com.sun.net.httpserver.Filter$Chain.doFilter (Filter.java:77)
at sun.net.httpserver.AuthFilter.doFilter (AuthFilter.java:82)
at com.sun.net.httpserver.Filter$Chain.doFilter (Filter.java:80)
at sun.net.httpserver.ServerImpl$Exchange$LinkHandler.handle (ServerImpl.java:685)
at com.sun.net.httpserver.Filter$Chain.doFilter (Filter.java:77)
at sun.net.httpserver.ServerImpl$Exchange.run (ServerImpl.java:657)
at java.util.concurrent.ThreadPoolExecutor.runWorker (ThreadPoolExecutor.java:1167)
at java.util.concurrent.ThreadPoolExecutor$Worker.run (ThreadPoolExecutor.java:641)
at java.lang.Thread.run (Thread.java:844)
Since "timestamp" is an optional field, would it be better to reduce such warning logs when it is unset in the metric sample?
Hi Prometheus,
This is Yang from OpenCensus. Last year we added an OpenCensus Prometheus exporter that exports metrics to Prometheus end points. I saw you added an optional
"timestamp"value as part of metric sample in #337 - on OpenCensus we haven't updated our exporter to set this field. However, when our users were using the OpenCensus Prometheus exporter, they got a bunch of warning logs saying (original issue: census-instrumentation/opencensus-java#1215):Since
"timestamp"is an optional field, would it be better to reduce such warning logs when it is unset in the metric sample?