2

I have web application and I log some info on user requests. I need to include client ip address in a log file name, so I'd get separate log file for each ip. Can I define some file naming pattern with parameters (ip in my case)? I have string ip variable.

File name example: mylog-127.0.0.1.log

Thanks

Timofei Davydik
  • 7,244
  • 7
  • 33
  • 59

2 Answers2

0

If you can switch to logback, I suggest you use SiftingAppender instead.

Jintian DENG
  • 3,152
  • 20
  • 22
0

Seems, I need to create appenders dynamically

Timofei Davydik
  • 7,244
  • 7
  • 33
  • 59