Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Misleading documentation about statsd client #13

Open
nicgirault opened this issue Jul 8, 2019 · 2 comments
Open

Misleading documentation about statsd client #13

nicgirault opened this issue Jul 8, 2019 · 2 comments

Comments

@nicgirault
Copy link

nicgirault commented Jul 8, 2019

Docs says the statsd lib is node-dogstatsd but I couldn't find the options I was looking for so I had a look in the code https://github.com/DataDog/node-connect-datadog/blob/master/lib/index.js#L4 and realized the doc was misleading: the statsd client is hot-shots.

Moreover typing definitions seems wrong:

image

I get the typescript error: Type 'StatsD' is missing the following properties from type 'StatsDClient': incrementBy, decrementBy

because the expected type comes from node-dogstatsd: import { StatsDClient } from 'node-dogstatsd'

@rochdev
Copy link
Member

rochdev commented Jul 8, 2019

This is a recent change from node-dogstatsd to hotshots since the latter is a lot more active. It looks like the TypeScript definitions are community-maintained at DefinitelyTyped. I can submit a PR but in the meantime I would recommend using declaration merging to resolve the error.

@vanessayuenn
Copy link

This has been fixed via DefinitelyTyped/DefinitelyTyped#45510!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants