class Honeybadger::Configuration

Defined in:

honeybadger/configuration.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new #

[View source]

Instance Method Detail

def api_key : String #

A Honeybadger API key.


[View source]
def api_key=(api_key : String) #

A Honeybadger API key.


[View source]
def development? : Bool #

Is the current environment considered a development environment?


[View source]
def development_environments : Array(String) #

The list of environments considered "development"


[View source]
def development_environments=(development_environments : Array(String)) #

The list of environments considered "development"


[View source]
def development_environments=(value : String) #

Configure development environment list with a string.

Used to set the value from an environment variable. Input is split on commas and striped of leading/trailing whitespace.

config.development_environments = "development, testing, staging"
config.development_environments # => ["development", "testing", "staging"]

[View source]
def endpoint : Path #

The API endpoint for sending Honeybadger payloads.


[View source]
def endpoint=(endpoint : Path) #

The API endpoint for sending Honeybadger payloads.


[View source]
def endpoint=(path : String) : String #

Configures API endpoint with a string.

Used to set the value from an environment variable.

config.endpoint = "http://new_api.honeybadger.io"
config.endpoint # => Path["http://new_api.honeybadger.io"]

[View source]
def environment : String | Nil #

The current app environment.


[View source]
def environment=(environment : String | Nil) #

The current app environment.


[View source]
def filter_keys : Array(String) #

A list of keys whose values are replaced with "[FILTERED]" in sensitive data objects.


[View source]
def filter_keys=(filter_keys : Array(String)) #

A list of keys whose values are replaced with "[FILTERED]" in sensitive data objects.


[View source]
def hostname : String #

The system or container hostname.


[View source]
def hostname=(hostname : String) #

The system or container hostname.


[View source]
def merge_log_context : Bool #

Merge the log context into the Honeybadger payload before sending errors to the reporting API.


[View source]
def merge_log_context=(merge_log_context : Bool) #

Merge the log context into the Honeybadger payload before sending errors to the reporting API.


[View source]
def project_root : String #

The path to the projects source code. Evaluated at compile time.


[View source]
def project_root=(project_root : String) #

The path to the projects source code. Evaluated at compile time.


[View source]
def report_data : Bool | Nil #

Explicitly override the development environment check. Nil = check for development environment True = always report data False = never report data


[View source]
def report_data=(report_data : Bool | Nil) #

Explicitly override the development environment check. Nil = check for development environment True = always report data False = never report data


[View source]
def report_data=(value : String) : Bool #

Configures report_data with a string.


[View source]
def report_data? : Bool #

Should Honeybadger.cr send data to the honeybadger api?

When report_data is unset, default to development? logic.


[View source]
def revision : String #

The project git revision. Evaluated at compile time.


[View source]
def revision=(revision : String) #

The project git revision. Evaluated at compile time.


[View source]
def set_from_env #

Reads configuration from honeybadger prefixed environment variables


[View source]