Getting lockdown with sentry-java and log4j 2.x

I’ve just upgraded from the raven library and having some problems getting logging working in production. Some logs get through but I was getting a lot of errors - I suspect a loop - where a sentry error was being logged back to the Sentry servers which eventually created an overload of errors in the time period.

My log4j2.xml contains…

...

on the console I see

SP WARN 09:42 AbstractConnection:93 - An exception due to the connection occurred, a lockdown will be initiated.
io.sentry.connection.ConnectionException: {“error”:“Event dropped due to filter”}
at io.sentry.connection.HttpConnection.doSend(HttpConnection.java:182) ~[sentry-1.5.2.jar:?]
at io.sentry.connection.AbstractConnection.send(AbstractConnection.java:71) [sentry-1.5.2.jar:?]
at io.sentry.connection.BufferedConnection.send(BufferedConnection.java:102) [sentry-1.5.2.jar:?]
at io.sentry.connection.BufferedConnection$Flusher.run(BufferedConnection.java:231) [sentry-1.5.2.jar:?]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:473) [?:1.7.0_151]
at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:304) [?:1.7.0_151]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:178) [?:1.7.0_151]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) [?:1.7.0_151]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1152) [?:1.7.0_151]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:622) [?:1.7.0_151]
at java.lang.Thread.run(Thread.java:748) [?:1.7.0_151]
Caused by: java.io.IOException: Server returned HTTP response code: 403 for URL: https://sentry.io/api/39352/store/
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1676) ~[?:1.7.0_151]
at sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java:254) ~[?:1.7.0_151]
at io.sentry.connection.HttpConnection.doSend(HttpConnection.java:157) ~[sentry-1.5.2.jar:?]
… 10 more

How do I see that the “filter” is which is dropping the event?

(For what it’s worth, we’ve been discussing this over support.)

For other viewers: you can adjust inbound filters at https://sentry.io/$ORG/$PROJECT/settings/filters/