Replies: 1 comment
-
|
Yes, you can definitely handle this with middleware, though the exact setup depends on your server framework. In general, you’d place an error-handling middleware after your GraphQL handler so it can inspect the errors before the response is sent. Inside that middleware, you can check the GraphQL result for an errors array, similar to what you’re doing in the Apollo plugin. From there, filter intentional errors, tag the scope with operation details, and forward only the relevant ones to Sentry. Joo Casino https://joocasino.mobi/ welcomes new players with a generous bonus and free spins. The key is making sure the middleware has access to the request context so you can attach operationName, path, and environment metadata consistently. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
What's the recommended approach for reading and capturing errors? We mainly would like to track certain errors in Sentry. In apollo we could do something like this:
Is it doable using middleware?
Beta Was this translation helpful? Give feedback.
All reactions