You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
use case:
a node app implements statsd metrics sending using this library.
user of this node app wants to configure his app so that it doesn't do any statsd sending.
i see 3 ways to implement this:
everywhere the app does calls on the client, wrap in disabled/enabled check (ugly)
app provides wrapper functions around library to wrap all calls in disabled/enabled check (still a bit ugly)
node-statsd doesn't do any statsd sending if the Client has this.host unset, or empty or null or whatever. (nice!)
the only thing needed to make this work is an edit in the Client.prototype.send function. I'm willing to create a patch for this, but since there's a bunch of socket-related changes pending, I would wait until that settles down.
The text was updated successfully, but these errors were encountered:
You should be able to accomplish this by setting the sample rate to -1. In this case the user would set a variable where the sample rate is either 1 or -1. When they want to turn it off they set it to -1 and it will never pass.
humphd
added a commit
to humphd/node-statsd
that referenced
this issue
Mar 15, 2013
use case:
a node app implements statsd metrics sending using this library.
user of this node app wants to configure his app so that it doesn't do any statsd sending.
i see 3 ways to implement this:
the only thing needed to make this work is an edit in the Client.prototype.send function. I'm willing to create a patch for this, but since there's a bunch of socket-related changes pending, I would wait until that settles down.
The text was updated successfully, but these errors were encountered: