Skip to content

Report handled errors to an external provider - #6

Merged
gustavofreze merged 3 commits into
mainfrom
feat/error-reporter
Aug 28, 2026
Merged

Report handled errors to an external provider#6
gustavofreze merged 3 commits into
mainfrom
feat/error-reporter

Conversation

@gustavofreze

Copy link
Copy Markdown
Member

Please follow the contributing guidelines.

Summary

What this pull request does.

Related issue

Closes #...

Checklist

  • Tests added or updated.
  • Documentation updated when applicable.
  • make review passes.
  • make tests passes.

- Add the ErrorReporter seam and the ReportedError context every reporter
  reads, so a handled error reaches error tracking without the middleware
  knowing the provider.
- Add the SentryReporter adapter, which either boots the SDK from the
  deployment values or captures onto a hub the application already holds.
- Add ReportingFilter, so the consumer decides which handled errors reach the
  provider and a client error never spends quota.
- Add ReportingPriority and PrioritizedError, the four level urgency scale
  stated once in neutral terms and translated by each adapter.
- Add ReportingContext and ReportingTags, the exception side and request side
  supplements a report carries, which is how a value resolved below the
  middleware crosses the PSR-7 immutability gap.
- Add RouteMiddleware, so a report carries the route the request matched
  instead of the raw path that names one request rather than one endpoint.
- Add withMessage, which settles the message the response answers with before
  the body is built, so no layer above parses and re-encodes it.
- Validate the headers a mapping rule declares, so a malformed field fails
  while the table is declared rather than on the request that would return it.
@gustavofreze
gustavofreze merged commit 6d14fa8 into main Aug 28, 2026
5 checks passed
@gustavofreze
gustavofreze deleted the feat/error-reporter branch August 28, 2026 13:49
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

Successfully merging this pull request may close these issues.

1 participant