Commit cc5e58a7 authored by Sean McGivern's avatar Sean McGivern

Merge branch '55611-always-load-metrics-the-last' into 'master'

Always load the metrics the last

Closes #55611

See merge request gitlab-org/gitlab-ce!23960
parents 80ff142c 77b8c2c1
# This file was prefixed with zz_ because we want to load it the last!
# See: https://gitlab.com/gitlab-org/gitlab-ce/issues/55611
# Autoload all classes that we want to instrument, and instrument the methods we
# need. This takes the Gitlab::Metrics::Instrumentation module as an argument so
# that we can stub it for testing, as it is only called when metrics are
......
......@@ -35,7 +35,7 @@ Using this method is in general preferred over directly calling the various
instrumentation methods.
Method instrumentation should be added in the initializer
`config/initializers/8_metrics.rb`.
`config/initializers/zz_metrics.rb`.
### Examples
......
......@@ -16,7 +16,7 @@ describe 'instrument_classes' do
end
it 'can autoload and instrument all files' do
require_relative '../../config/initializers/8_metrics'
require_relative '../../config/initializers/zz_metrics'
expect { instrument_classes(config) }.not_to raise_error
end
end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment