File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -188,7 +188,7 @@ gem 'prometheus_exporter'
188188In an initializer:
189189
190190``` ruby
191- unless Rails .env == " test"
191+ unless Rails .env. test?
192192 require ' prometheus_exporter/middleware'
193193
194194 # This reports stats per request like HTTP status and timings
@@ -341,7 +341,7 @@ You may also be interested in per-process stats. This collects memory and GC sta
341341
342342``` ruby
343343# in an initializer
344- unless Rails .env == " test"
344+ unless Rails .env. test?
345345 require ' prometheus_exporter/instrumentation'
346346
347347 # this reports basic process stats like RSS and GC info
@@ -522,7 +522,7 @@ All metrics have labels for `job_name` and `queue_name`.
522522In an initializer:
523523
524524``` ruby
525- unless Rails .env == " test"
525+ unless Rails .env. test?
526526 require ' prometheus_exporter/instrumentation'
527527 PrometheusExporter ::Instrumentation ::DelayedJob .register_plugin
528528end
@@ -548,7 +548,7 @@ All metrics have labels for `job_name` and `queue_name`.
548548Capture [ Hutch] ( https://github.com/gocardless/hutch ) metrics (how many jobs ran? how many failed? how long did they take?)
549549
550550``` ruby
551- unless Rails .env == " test"
551+ unless Rails .env. test?
552552 require ' prometheus_exporter/instrumentation'
553553 Hutch ::Config .set(:tracer , PrometheusExporter ::Instrumentation ::Hutch )
554554end
You can’t perform that action at this time.
0 commit comments