You can check the property closed on the specific appender. Since closed is a protected field, you may need to set it visible before accessing using java reflection.
How to check if LOG4J file appender is closed?
-
05-03-2022 - |
Question
How can I check if LOG4J file appender is closed?
Solution
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow