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
What
Deprecate the following methods of sprockets_statsd.tornado.RequestHandler in favor of the methods provided by self.application.statsd_connector
increase_counter ⟶ incr
record_timing ⟶ timing
execution_timer ⟶ timer
Why
The RequestHandler specific methods differ slightly from the methods provided by the connector. Specifically, they concatenate method arguments to create the metric path. This can cause confusion when doing something like this:
increase_counter('errors.retries', 5)
One might expect that to increment errors.retries by 5, but it actually increases errors.retries.5 by 1.
Also - these methods are specific only to a Tornado application. I've started using sprockets-statsd in a non-Tornado application and would like consistent method calls across my applications.
The text was updated successfully, but these errors were encountered:
What
Deprecate the following methods of
sprockets_statsd.tornado.RequestHandler
in favor of the methods provided byself.application.statsd_connector
increase_counter
⟶incr
record_timing
⟶timing
execution_timer
⟶timer
Why
The
RequestHandler
specific methods differ slightly from the methods provided by the connector. Specifically, they concatenate method arguments to create the metric path. This can cause confusion when doing something like this:One might expect that to increment
errors.retries
by5
, but it actually increaseserrors.retries.5
by1
.Also - these methods are specific only to a Tornado application. I've started using sprockets-statsd in a non-Tornado application and would like consistent method calls across my applications.
The text was updated successfully, but these errors were encountered: