Class: AppfluxRuby::MessageBuilders::Bugflux

Inherits:
Base
  • Object
show all
Defined in:
lib/appflux_ruby/message_builders/bugflux.rb

Constant Summary collapse

ENV_REQUEST_METHODS =
i( path host scheme user_agent port url ip
content_type request_method referrer )
ENV_REQUEST_KEYS =
i( SERVER_PROTOCOL SERVER_SOFTWARE )
ENV_EXCEPTION_METHODS =
i( backtrace message cause class )
SUPPORTED_BACKGROUND_JOB_PROCESSORS =
%w(delayed_job sidekiq)

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(exception, rack_env) ⇒ Bugflux

Returns a new instance of Bugflux.



49
50
51
52
53
54
# File 'lib/appflux_ruby/message_builders/bugflux.rb', line 49

def initialize exception, rack_env
  super(exception, rack_env)

  @notice[:bugflux] = Hash.new { |hsh, key| hsh[key] = Hash.new }
  @bugflux_notice = @notice[:bugflux]
end

Class Method Details

.build(exception, rack_env) ⇒ Object



71
72
73
# File 'lib/appflux_ruby/message_builders/bugflux.rb', line 71

def self.build exception, rack_env
  new(exception, rack_env).build
end

Instance Method Details

#buildObject



56
57
58
59
60
61
62
63
64
65
66
67
68
69
# File 'lib/appflux_ruby/message_builders/bugflux.rb', line 56

def build
  super
  add_app_id
  add_request_data
  add_params
  add_exception_data
  add_env
  add_headers
  add_session_data
  add_background_job_info
  add_custom_tabs

  @notice
end