opentelemetry.io icon indicating copy to clipboard operation
opentelemetry.io copied to clipboard

Fill remaining JS Metrics docs gaps

Open cartermp opened this issue 3 years ago • 8 comments

The following concepts still need to be documented with working code samples and good commentary:

  • [x] observable counter
  • [x] observable updowncounter
  • [x] observable gauge
  • [ ] views

You can also use this as a guide, at least for Views: https://github.com/open-telemetry/opentelemetry-js/blob/main/doc/metrics.md

cartermp avatar Nov 28 '22 14:11 cartermp

Hi! I'd like to take on this issue - it will be my first across any OTEL github repo. I am very familiar with the Go SDK and have instrumented several micro-services at my startup with OTEL - this will be my first time looking at the JavaScript docs though.

Omkar-Waingankar avatar Jan 06 '23 19:01 Omkar-Waingankar

Should the code samples be added inline in metrics.md?

Omkar-Waingankar avatar Jan 06 '23 19:01 Omkar-Waingankar

@Omkar-Waingankar Thanks for offering! Code samples should be added inline, yes.

What I did with the first cut was:

  • Use this as a bit of a reference: https://github.com/open-telemetry/opentelemetry-js/blob/main/doc/metrics.md (it has various gaps but it's a good point of reference)
  • Build a sample app and tweak/document/tweak/document

I found the observable instruments ...difficult. Not necessarily difficult to use, but their behavior was confusing to me (e.g., being able to decrease a value in an observablecounter) and the spec wasn't entirely clear either. So it's worth a shot, but if you find yourself treading water then we can bubble it up to others.

cartermp avatar Jan 06 '23 20:01 cartermp

Thanks for the tips!

Omkar-Waingankar avatar Jan 06 '23 20:01 Omkar-Waingankar

https://github.com/open-telemetry/opentelemetry.io/pull/2144 ^I've made a PR here, but I'm not sure how to link it to this issue

Omkar-Waingankar avatar Jan 06 '23 22:01 Omkar-Waingankar

@cartermp I've pushed a new set of updates to the PR above, where I address some comments from other contributors and add a section on views

Omkar-Waingankar avatar Jan 09 '23 16:01 Omkar-Waingankar

Can we add tracking for Metric and Log Exporters - currently missing from https://opentelemetry.io/docs/instrumentation/js/exporters/

domdomegg avatar Feb 27 '23 11:02 domdomegg

Can we add tracking for Metric and Log Exporters - currently missing from https://opentelemetry.io/docs/instrumentation/js/exporters/

Sure, this would be a worthwile addition

svrnm avatar Feb 27 '23 14:02 svrnm