diff options
author | Eileen Uchitelle <eileencodes@gmail.com> | 2018-06-12 15:36:54 -0400 |
---|---|---|
committer | Eileen Uchitelle <eileencodes@gmail.com> | 2018-06-12 15:37:23 -0400 |
commit | e0874b6f88509270d7603184ecd158d55df7204f (patch) | |
tree | 3fce037f95b5e951c63014437cbdbdb512f54f08 /actionpack/lib/action_dispatch | |
parent | 39cb84e8bdd4b9a35d68b33222a174d2350aee89 (diff) | |
download | rails-e0874b6f88509270d7603184ecd158d55df7204f.tar.gz rails-e0874b6f88509270d7603184ecd158d55df7204f.tar.bz2 rails-e0874b6f88509270d7603184ecd158d55df7204f.zip |
Add ability to configure cache notifications info
This may seem like an unnecessary refactoring but some apps want / need
to configure the information passed to the query cache logger. In order
to do that we can add a method here that can be easily overridden by the
app itself, rather than hacking the query cache logger to include that
information.
To override apps can call
```
def cache_notifications_info
super.merge(connected_host: "hostname")
end
```
This will take what's already in the query cache logger and add
`@something="yea"` to the object.
At GitHub we use this to log the number of queries that are cached, the
connection host and the connection url.
Diffstat (limited to 'actionpack/lib/action_dispatch')
0 files changed, 0 insertions, 0 deletions