Skip to content
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

Add logging for failed subscriber creation #1564

Open
5 tasks
TylerMatteo opened this issue Oct 24, 2024 · 3 comments
Open
5 tasks

Add logging for failed subscriber creation #1564

TylerMatteo opened this issue Oct 24, 2024 · 3 comments
Assignees

Comments

@TylerMatteo
Copy link
Contributor

TylerMatteo commented Oct 24, 2024

Add logging to the /subscribers POST endpoint that logs failed subscriber creation to Sentry

  • Configure ZAP Search back end to integrate with Sentry for error logging
  • Use the existing zap-search-server app in Sentry
  • Use job id returned by contact creation endpoint to poll Import Contacts Status endpoint until the job returns a completed, or errored, or failed status.
  • If any unsuccessful status is reported, or if maximum polling time limit is reached, log details to Sentry with user's email, anonymous_id uuid, and selected subscription topics
  • Existing /subscribers endpoint should still return when the original contact creation endpoint returns successfully.
@TylerMatteo
Copy link
Contributor Author

@dhochbaum-dcp I don't have an exact polling rate and max time limit in mind but in general it can be longer with longer pauses between attempts - something like 5 minutes, checking every 10-30 seconds.

@TylerMatteo
Copy link
Contributor Author

@dhochbaum-dcp For context, I asked Sendgrid about webhooks to handle this sort of thing and they basically said to do what I described about:
Image

@TylerMatteo
Copy link
Contributor Author

@dhochbaum-dcp - @horatiorosa did a spike looking at different Sentry packages for Nest a while back because, at the time, Sentry didn't have an official one. However, they came out with one recently so I say let's try using that :D

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants