You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
*`Sentry.capture_exception/1` now returns a `Task` instead of `{:ok, PID}`
15
+
* Sentry.Plug `:scrubber` option has been removed in favor of the more descriptive `:body_scrubber`option, which defaults to newly added `Sentry.Plug.default_scrubber/1`
16
+
* New option for Sentry.Plug `:header_scrubber` defaults to newly added `Sentry.Plug.default_header_scrubber/1`
17
+
* Request bodies were not previously sent by default. Because of above change, request bodies are now sent by default after being scrubbed by default scrubber. To prevent sending any data, `:body_scrubber` should be set to `nil`
Sentry.Plug provides basic funcitonality to handle Plug.ErrorHandler.
5
+
6
+
To capture errors, simply put the following in your router:
7
+
8
+
.. code-block:: elixir
9
+
10
+
use Sentry.Plug
11
+
12
+
Optional settings
13
+
------------------
14
+
15
+
.. describe:: body_scrubber
16
+
17
+
The function to call before sending the body of the request to Sentry. It will default to ``Sentry.Plug.default_body_scrubber/1``, which will remove sensitive parameters like "password", "passwd", "secret", or any values resembling a credit card.
18
+
19
+
.. describe:: header_scrubber
20
+
21
+
The function to call before sending the headers of the request to Sentry. It will default to ``Sentry.Plug.default_header_scrubber/1``, which will remove "Authorization" and "Authentication" headers.
22
+
23
+
.. describe:: request_id_header
24
+
25
+
If you're using Phoenix, Plug.RequestId, or another method to set a request ID response header, and would like to include that information with errors reported by Sentry.Plug, the `:request_id_header` option allows you to set which header key Sentry should check. It will default to "x-request-id", which Plug.RequestId (and therefore Phoenix) also default to.
0 commit comments