mirror of
https://github.com/mastodon/mastodon.git
synced 2024-11-21 12:05:07 +01:00
Allow specifying STATSD_NAMESPACE (#5700)
This commit is contained in:
parent
fbef909c2a
commit
546257bc7f
@ -4,7 +4,7 @@ if ENV['STATSD_ADDR'].present?
|
|||||||
host, port = ENV['STATSD_ADDR'].split(':')
|
host, port = ENV['STATSD_ADDR'].split(':')
|
||||||
|
|
||||||
statsd = ::Statsd.new(host, port)
|
statsd = ::Statsd.new(host, port)
|
||||||
statsd.namespace = ['Mastodon', Rails.env].join('.')
|
statsd.namespace = ENV.fetch('STATSD_NAMESPACE') { ['Mastodon', Rails.env].join('.') }
|
||||||
|
|
||||||
::NSA.inform_statsd(statsd) do |informant|
|
::NSA.inform_statsd(statsd) do |informant|
|
||||||
informant.collect(:action_controller, :web)
|
informant.collect(:action_controller, :web)
|
||||||
|
Loading…
Reference in New Issue
Block a user