Class: ScoutApm::LayerErrorConverter
- Inherits:
-
LayerConverterBase
- Object
- LayerConverterBase
- ScoutApm::LayerErrorConverter
- Defined in:
- lib/scout_apm/layer_converter.rb
Instance Attribute Summary
Attributes inherited from LayerConverterBase
#request, #root_layer, #walker
Instance Method Summary collapse
Methods inherited from LayerConverterBase
Constructor Details
This class inherits a constructor from ScoutApm::LayerConverterBase
Instance Method Details
#call ⇒ Object
72 73 74 75 76 77 78 79 80 81 82 83 84 85 |
# File 'lib/scout_apm/layer_converter.rb', line 72 def call scope = scope_layer # Should we mark a request as errored out if a middleware raises? # How does that interact w/ a tool like Sentry or Honeybadger? return {} unless scope return {} unless request.error? = MetricMeta.new("Errors/#{scope.legacy_metric_name}", {}) stat = MetricStats.new stat.update!(1) { => stat } end |