Many thanks to Volkan and Piotr for responses.



I believe I have clarified some important issues:

- The logging currently does not have features available that can support my 
use case.

- Why the Kafka appender is scheduled to be removed from the log repository and 
the reasons behind it.

- The more appropriate way to maintain the Kafka appender is within the Kafka 
community.




I have no intention of disrupting the existing deployment plans of the 
community,

I truly appreciate everyone’s warm responses and help.




Best,

Yuepeng


At 2025-01-28 04:49:54, "Piotr P. Karwasz" <pi...@mailing.copernik.eu> wrote:
>Hi Volkan,
>
>On 27.01.2025 20:20, Volkan Yazıcı wrote:
>> Have you considered the async. appender
>> <https://logging.apache.org/log4j/2.x/manual/appenders/delegating.html#AsyncAppender>?
>> It can be configured to drop to requests if the buffer is full, i.e., Kafka
>> is not keeping up.
>
>IIRC the Kafka Appender and asynchronous components don't like each 
>other. The Kafka client library uses asynchronous calls and the Kafka 
>asynchronous thread also generates log events. This can end up in 
>problems like #2893[1].
>
>When it comes to the Kafka Appender, I think a big rewrite is needed.
>
>Piotr
>
>[1] https://github.com/apache/logging-log4j2/issues/2893

Reply via email to