Setting up sentry for the gateway

I have setup sentry for my tyk project using Log Data

I am trying to figure out how to trigger a 5xx to ensure that it actually works. One of the things I’ve tried it so have a rewrite rule that points to an API definition that does not exist.

Correctly, I am getting a 500 with body

{"error": "Can't detect loop target"}

but this does not trigger a Sentry.

I think a wider question which is a bit unclear to me is what type of errors are reported to sentry inside the gateway? I see upstream errors are not included but I would expect my example to be included.

Hi @periclestheo, do you see the error in the gateway logs as well?

Cause I think the sentry logs are configured for only panic, fatal and error logs. So for example a redis connection error or dashboard connection issue would trigger it.

I also tested with a not found 404 error when enabling 404 logs and discovered it also logs that as well. Basically, anything that is within the realms of dangerous logs should trigger it.

Or you could try modifying the source and creating a custom gateway that also logs info and debug messages.