-
-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
derive jason encoder for request #3182
Conversation
BundleMonUnchanged files (7)
No change in files bundle size Final result: ✅ View report in BundleMon website ➡️ |
@@ -36,6 +36,10 @@ defmodule Plausible.SentryFilter do | |||
%{event | fingerprint: ["db_connection", reason]} | |||
end | |||
|
|||
def before_send(%{extra: %{request: %Plausible.Ingestion.Request{}}} = event) do | |||
%{event | fingerprint: ["ingestion_request"]} | |||
end |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll need to try that out...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sentry.capture_message("oof", extra: %{request: %Plausible.Ingestion.Request{}})
https://eh-uo.sentry.io/share/issue/1cb9ceadb737491f8f230c1ec391e0bf/
🥲 "shared" issue doesn't include fingerprint info...
Here's what I'm seeing on my dashboard:
a595f74
to
c185887
Compare
@@ -27,6 +27,7 @@ defmodule Plausible.Ingestion.Request do | |||
|
|||
@max_url_size 2_000 | |||
|
|||
@primary_key false |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Otherwise {"id": null}
is added to all requests during encoding.
c185887
to
0e99d0d
Compare
0e99d0d
to
f05ba78
Compare
test "enforces fingerprint for ingestion request" do | ||
event = | ||
Sentry.Event.create_event( | ||
message: "oof", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
beautiful :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
excellent
Great work! |
Changes
Continuing from #3180
Tests
Changelog
Documentation
Dark mode