This week's book giveaway is in the OCAJP 8 forum.
We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line!
See this thread for details.
The moose likes Web Services and the fly likes Logging with WSS4j Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of OCA Java SE 8 Programmer I Study Guide this week in the OCAJP 8 forum!
JavaRanch » Java Forums » Java » Web Services
Bookmark "Logging with WSS4j" Watch "Logging with WSS4j" New topic

Logging with WSS4j

Andrew Prinoli

Joined: Jan 11, 2007
Posts: 22
Hello ,
I'm using Tomcat6 + Axis 1+wss4j.
I have to modify something in wss4j's source code but I can't test its results...but I couldn't enable logging with log4j..
How should I do that???
I could be able to do log with log4j for axis..using the following properties file , placed in folder \Tomcat\webapps\axis\WEB-INF\classes. :

# Set root logger level to WARN and its only appender to A1.
log4j.rootLogger=WARN, A1
# show DEBUG for SOAPPart method
# A1 is set to be a ConsoleAppender.
# log4j.appender.A1=org.apache.log4j.ConsoleAppender
# A1 uses PatternLayout.
log4j.appender.A1.layout.ConversionPattern=%-4r [%t] %-5p %c %x - %m%n

How do I enable logging with wss4j?
I tried putting the properties file included with wss4j's source but with no luck..
Thanks in Advance
Ladislav Lencucha

Joined: Oct 28, 2012
Posts: 2
First of all, you have to change the logging from apache.commons.Logging to Log4j:

Then your setup will work correctly.
I agree. Here's the link:
subject: Logging with WSS4j
jQuery in Action, 3rd edition