Log4j2 with log4j2.xml Configuration Example

You may also like...

Leave a Reply

2 Comments on "Log4j2 with log4j2.xml Configuration Example"

avatar
  Subscribe  
newest oldest
Notify of
NathanR
Guest
NathanR

Hi,
I get the console logs but not the file.
Any idea?
Where is the file saved? maybe I’m just not seeing it?

Thanks

Memorynotfound.com
Guest
Memorynotfound.com

By default, when you don’t specify the full path, the log file is saved at the root of your project. You can optionally specify the file-path in the fileName attribute. For example:
– mac/linux/unix users can add a path like “/tmp/logfile.log”
– windows users can add a path like “C:tmplogfile.log”