[RFC] 3.0?
See original GitHub issueI am thinking I want to port this lib to Typescript and add some more integrations namely Prometheus.
Maybe finally clean up somethings on the Metrics objects, such as toJson() being the primary manner of getting data when half the time it doesn’t return JSON.
As I am basically the only one care and feeding this lib, I will leave this issue open for a while and see if anyone has comments and see if I have time to start this process.
Closes #32
In the process maybe we can get some integration tests up and running so that PRs like dependency auto bumps can be streamlined and we can make sure we stay up to date to prevent security issues.
I think porting to TS can be done 1 package at a time starting with core.
I am going to CC anyone who has ever contributed for visibility:
CC: @felixge, @mantoni, @Qard, @oliverzy, @csabapalfi, @dohse, @anacasner, @horte, @bnoordhuis, @tuckbick, @tlisonbee, @joeybaker, @hugebdu, @avolfson, @arlolra, @OlegIlyenko
Issue Analytics
- State:
- Created 3 years ago
- Reactions:4
- Comments:12 (7 by maintainers)

Top Related StackOverflow Question
@fieldju we would definitely be happy to have your help on opentelemetry js. While true that the metrics sdk is only seeing about 1000 downloads weekly right now, it is still in beta phase and is somewhat incomplete. I would say if you are going to deprecate this library in favor of otel, you should likely familiarize yourself with the state of the project and consider waiting until we launch GA toward the end of the summer before beginning to actively push your users to it. We may also be able to work on some sort of compatibility bridge similar to what we have for opentracing on the trace side that would allow your users to take advantage of opentelemetry in stages without making too many code changes all at once.
Metrics is under active development right now. You can see the full details of what will be supported in the spec here. Without knowing exactly how you define the difference between a gauge and a meter it is difficult to answer exactly, but you are probably looking for the ValueRecorder and the ValueObserver.
There is currently not support or specification for timers, but I believe there has been active discussion in the specification around that.
I would vote leave it as-is and encourage users to migrate. There are some major users that I’m sure would appreciate not needing to move so immediately and hopefully not needing to move twice. (once to v2 and then again to otel)