Class: Rollday::Configuration
- Inherits:
-
Object
- Object
- Rollday::Configuration
- Includes:
- ClassComposer::Generator
- Defined in:
- lib/rollday/configuration.rb
Constant Summary collapse
- ROLLBAR_LEVELS =
[ DEBUG = :debug, INFO = :info, WARNING = :warning, ERROR = :error, CRITICAL = :critical ]
- DEFAULT_ROLLBAR_LEVEL =
WARNING
- DEFAULT_STATUS_CODE_REGEX =
/[45]\d\d$/
- DEFAULT_MESSAGE_PROC =
->(status, phrase, body, path, domain) { "[#{status}]: #{domain} - #{path}" }
- DEFAULT_LEVEL_PROC =
->(_status) { DEFAULT_ROLLBAR_LEVEL }
- ROLLBAR_VALIDATOR =
Proc.new do |value| value.is_a?(Proc) || ROLLBAR_LEVELS.include?(value) end
- EXCEPTION_CLASS_DEFAULT =
-> (status, phrase, body, path, domain) { Rollday::Faraday }
Instance Method Summary collapse
- #person_scope ⇒ Object
- #register_middleware! ⇒ Object
- #use_default_client_middleware! ⇒ Object
- #use_default_middleware! ⇒ Object
Instance Method Details
#person_scope ⇒ Object
43 44 45 46 47 |
# File 'lib/rollday/configuration.rb', line 43 def person_scope return -> {} unless use_person_scope @person_scope || Rollbar.scope.scope_object.raw[:person] || -> {} end |
#register_middleware! ⇒ Object
57 58 59 |
# File 'lib/rollday/configuration.rb', line 57 def register_middleware! Rollday.register_middleware! end |
#use_default_client_middleware! ⇒ Object
53 54 55 |
# File 'lib/rollday/configuration.rb', line 53 def use_default_client_middleware! Rollday.use_default_client_middleware! end |
#use_default_middleware! ⇒ Object
49 50 51 |
# File 'lib/rollday/configuration.rb', line 49 def use_default_middleware! Rollday.use_default_middleware! end |