https://issues.apache.org/jira/browse/LOG4J2-1797
Added comment.
On Thu, May 11, 2017 at 4:11 PM, Matt Sicker wrote:
> So this is something to consider with an async appender API. I don't
> remember the ticket number, but there's one about such an API, and handling
>
So this is something to consider with an async appender API. I don't
remember the ticket number, but there's one about such an API, and handling
recursive logging may be handled more generically in such an API.
On 11 May 2017 at 07:58, Mikael Ståldal wrote:
> The
The Kafka client library spawns its own threads, so this recursive logging
is most likely done on another thread. That explains why the
AppenderControl prevention does not work.
So we should keep the prevention in KafkaAppender.
On Thu, May 11, 2017 at 2:50 PM, Apache
How does AppenderControl not prevent recursive logging? If the appender gets
called a second time on the thread then it will ignore the event. If the
appender or Kafka are creating new threads that are logging then you could get
the behavior you mention, but I don't see how that could be
The Kafka appender uses the Kafka client library, and that client library
does it's own logging through SLF4J, it always emits a few log messages at
DEBUG level on each message sent.
If you have log4j-slf4j-impl in classpath and enable DEBUG logging through
KafkaAppender, you will get recursive