- Added
Introspection-Token
as valid header (X-Introspection-Token
will still work for backwards compatibility, but is not preferred) - Added ability to set introspection token when adding plug to pipeline via the
:token
parameter as an MFA - Removed some unecessary debug logs
- Some error messages changed
- Internal refactors
- Removed JSON encoding of errors, now log plain maps handed to
Kernel.inspect
- Handle exceptions formatting logs as JSON
- Log expected service error as debug unless to reduce log volume in prod by default
WARNING: This is a breaking change. Before update read the new steps to configure the library in the README or bellow:
- add the following in your
config.exs
in order to bypass introspection(The name of the env varconfig :vigil, token: System.get_env("INTROSPECTION_TOKEN")
INTROSPECTION_TOKEN
is convention. Obviously if the value is stored under a different name in your service update it accordingly) - Internal code refactoring and cleaning
- Converts :warnings into :debug
- Improve warnings message with original error
- Removed logging information of full connection struct to prevent leakage of sensitive data in logs.
- Improved Logging and Exception Handling
- Scenario where known crash occured now prevented and/or logged.
- Fixed bug where options were not being processed correctly
- Added sanity checks in the unit tests for
call/2
andinit/1
- Improved generalized exception handling
- Log levels now default to
:warning
instead of:error
- Log level can now be configured in plug options
- Change dependency from plug_cowboy to plug
- Change dependency from poison to jason