File tree 1 file changed +7
-5
lines changed
1 file changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -7,17 +7,19 @@ def initialize(app)
7
7
@app = app
8
8
end
9
9
10
- def call ( env )
10
+ def call ( env , & statsd_block )
11
11
metrics = Metrics . new ( env )
12
12
13
13
AutoScalingMetrics ::Reporter . start if ENV [ "ECS_SETUP" ]
14
14
15
15
unless metrics . ignore?
16
16
tags = [ "request_method:#{ env [ "REQUEST_METHOD" ] } " ]
17
- if Object . const_defined? ( :StatsdDdog )
18
- StatsdDdog . timing ( "rails.request.queue_time" , metrics . queue_time , tags :)
19
- StatsdDdog . timing ( "rails.request.queue_time.network_time" , metrics . network_time , tags :)
20
- end
17
+
18
+ ActiveSupport ::Notifications . instrument ( "request_queue_time.timings" , extra : {
19
+ tags : tags ,
20
+ queue_time : metrics . queue_time ,
21
+ network_time : metrics . network_time
22
+ } )
21
23
22
24
env [ "request_queue_time" ] = metrics . queue_time
23
25
env [ "request_network_time" ] = metrics . network_time
You can’t perform that action at this time.
0 commit comments