• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Devaka Cooray
  • Tim Cooke
Sheriffs:
  • Rob Spoor
  • Liutauras Vilda
  • paul wheaton
Saloon Keepers:
  • Tim Holloway
  • Tim Moores
  • Mikalai Zaikin
  • Carey Brown
  • Piet Souris
Bartenders:
  • Stephan van Hulst

Tomcat, @WebFault logging

 
Ranch Hand
Posts: 333
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have a webservice that uses JAX-WS running in a Tomcat container.
The Service uses log4j as it logger, while Tomcat is using Java.util.logging (or rather its extension to it).

We have the service logging to its own log file, so as to keep the catalina log file for tomcat logging and the service log file for the service.

However when we get a service exception, it is to be logged in both logs, now i have tried all ways i can think of, and short of removing the console appender/handler from the tomcat configuration I cant get the exception to remain in the service log file.

I have checked for System.out and System.err and also for Throwable.printStackTrace and we are clean of those.

So how is this exception getting logged by both log files? Given that it seems to be the console handler that is logging the exception, I was wondering if it could be to do with the @WebFault annotation our exception has, that perhaps tomcat was reading and logging these exceptions at the container level?

I will be writing an experiment, but thought i would ask teh question here, in case there was something else I may have missed.

Thanks
G
 
Don't touch me. And dont' touch this tiny ad:
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic