Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

servlet loggin not working (log4j)

 
Alessandro Ilardo
Ranch Hand
Posts: 218
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As suggested by someone oy you I tried to implemet in my servlet the log4j, but it isn't log anything.
Can anyone of you have look and tell me where the mistake is?

  • first I placed the log4j-1.2.13.jar in the lib folder.
  • then I wrote a configuration file:


  • the folder indicated has write permits,
  • I placed this config. file in the class folder.
  • [list]In my servlet I inserted this code: [/list]
    in the init
    and in the catch statement


    Please, have a look, and tell if I made any mistakes.
    ps: any other suggestions are welcome.

    Thank in advance

     
    David O'Meara
    Rancher
    Posts: 13459
    Android Eclipse IDE Ubuntu
    • Mark post as helpful
    • send pies
    • Quote
    • Report post to moderator
    you've specified a directory, but not the file name. I'm not sure about how case sensitive log4J is, but you may want to try:



    'layout can be lowercase, but I'm not sure if the 'MaxFileSize' works with the Daily appender. Or maybe it does.

    Dave
     
    • Post Reply
    • Bookmark Topic Watch Topic
    • New Topic