Honeybadger v0.13.0 Honeybadger.Filter.Default View Source
The default implementation for the filter
configuration. Removes
keys listed in filter_keys
from maps and respects the
filter_disable_*
configuration values.
Link to this section Summary
Functions
Filter breadcrumbs. This filter function recieves a list of Breadcrumb structs. You could use any Enum function to constrain the set. Let's say you want to remove any breadcrumb that have metadata that contain SSN
For applications that use Honeybadger.Plug
, filter the cgi_data.
Filter the context Map. The context is a map of application supplied data.
Filter the error message string. This is the message from the most recently thrown error.
For applications that use Honeybadger.Plug
, filters the query parameters.
The parameters is a map of String.t
to String.t
, e.g.
For applications that use Honeybadger.Plug
, filter the session.
Link to this section Functions
Filter breadcrumbs. This filter function recieves a list of Breadcrumb structs. You could use any Enum function to constrain the set. Let's say you want to remove any breadcrumb that have metadata that contain SSN:
def filter_breadcrumbs(breadcrumbs) do Enum.reject(breadcrumbs, fn breadcrumb -> do
Map.has_key?(breadcrumb.metadata, :ssn)
end) end
Callback implementation for Honeybadger.Filter.filter_breadcrumbs/1
.
For applications that use Honeybadger.Plug
, filter the cgi_data.
cgi_data
is a map of String.t
to String.t
which includes HTTP headers
and other pre-defined request data (including PATH_INFO
, QUERY_STRING
,
SERVER_PORT
etc.).
Callback implementation for Honeybadger.Filter.filter_cgi_data/1
.
Filter the context Map. The context is a map of application supplied data.
Callback implementation for Honeybadger.Filter.filter_context/1
.
Filter the error message string. This is the message from the most recently thrown error.
Callback implementation for Honeybadger.Filter.filter_error_message/1
.
For applications that use Honeybadger.Plug
, filters the query parameters.
The parameters is a map of String.t
to String.t
, e.g.:
%{"user_name" => "fred", "password" => "12345"}
Callback implementation for Honeybadger.Filter.filter_params/1
.
For applications that use Honeybadger.Plug
, filter the session.
Callback implementation for Honeybadger.Filter.filter_session/1
.