diff options
author | Pratik Naik <pratiknaik@gmail.com> | 2015-10-09 09:10:51 -0500 |
---|---|---|
committer | Pratik Naik <pratiknaik@gmail.com> | 2015-10-09 09:10:51 -0500 |
commit | 1d4d274b0777793a8d39f76ded6a6b292f97abb0 (patch) | |
tree | f20a75cf725ffb9b2bf951b47b896be77a6e46fe /lib/action_cable | |
parent | 5858bf3bec7d72361116e84d9bcde5daa5195ea2 (diff) | |
download | rails-1d4d274b0777793a8d39f76ded6a6b292f97abb0.tar.gz rails-1d4d274b0777793a8d39f76ded6a6b292f97abb0.tar.bz2 rails-1d4d274b0777793a8d39f76ded6a6b292f97abb0.zip |
Include request id in statistics to make it to search the logs
Diffstat (limited to 'lib/action_cable')
-rw-r--r-- | lib/action_cable/connection/base.rb | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/action_cable/connection/base.rb b/lib/action_cable/connection/base.rb index de1369f009..cd7f76f118 100644 --- a/lib/action_cable/connection/base.rb +++ b/lib/action_cable/connection/base.rb @@ -111,7 +111,12 @@ module ActionCable # Return a basic hash of statistics for the connection keyed with `identifier`, `started_at`, and `subscriptions`. # This can be returned by a health check against the connection. def statistics - { identifier: connection_identifier, started_at: @started_at, subscriptions: subscriptions.identifiers } + { + identifier: connection_identifier, + started_at: @started_at, + subscriptions: subscriptions.identifiers, + request_id: @env['action_dispatch.request_id'] + } end def beat |