Method: Gitlab::Puma::ErrorHandler#execute

Defined in:
lib/gitlab/puma/error_handler.rb

#execute(ex, env, status_code) ⇒ Object



16
17
18
19
20
21
22
23
24
25
26
27
28
29
# File 'lib/gitlab/puma/error_handler.rb', line 16

def execute(ex, env, status_code)
  # Puma v6.4.0 added the status_code argument in
  # https://github.com/puma/puma/pull/3094
  status_code ||= 500

  Gitlab::ErrorTracking.track_exception(
    ex,
    { puma_env: env, status_code: status_code },
    { handler: 'puma_low_level' }
  )

  # note the below is just a Rack response
  [status_code, {}, message]
end