Did you add a handler to your classpath?
My example handler is:
package com.jankester.axis.handler;
import org.apache.axis.*;
import org.apache.axis.handlers.BasicHandler;
import org.apache.log4j.Logger;
public class SOAPMonitor extends BasicHandler {
private static Logger logger =
Logger.getLogger(SOAPMonitor.class.getName());
public void invoke(MessageContext msgContext) throws AxisFault {
if (msgContext.getPastPivot())
{
Message inMsg = msgContext.getRequestMessage();
Message outMsg = msgContext.getResponseMessage();
if (inMsg != null)
{
logger.info(":::SOAP Request:::");
logger.info(inMsg.getSOAPPartAsString());
logger.info(":::/SOAP Request:::");
}
if (outMsg != null)
{
logger.info(":::SOAP Response:::");
logger.info(outMsg.getSOAPPartAsString());
logger.info(":::/SOAP Response:::");
}
}
}
public void undo(MessageContext msgContext) {
}
}
Regards, Jan.
-----Mensaje original-----
De: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Enviado el: jueves, 04 de diciembre de 2003 12:13
Para: [EMAIL PROTECTED]
Asunto: R�f. : RE: Client handler
I've tried your solution and I get this error :
org.apache.axis.ConfigurationException: No engine configuration file -
aborting!
Which file is missing ?
Valerie
"Jan Kester" <[EMAIL PROTECTED]> sur 04/12/2003 11:38:55
Veuillez r�pondre � [EMAIL PROTECTED]
Pour : <[EMAIL PROTECTED]>
cc :
Objet : RE: Client handler
The client-config.wsdd has to be in the client's execute classpath.
In here you can define a handler. There are plenty of examples on internet.
My client-config.wsdd has:
<?xml version="1.0" encoding="UTF-8"?>
<deployment xmlns="http://xml.apache.org/axis/wsdd/"
xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<handler name="log" type="java:com.jankester.axis.handler.SOAPMonitor" />
<globalConfiguration>
<requestFlow>
<handler type="log"/>
</requestFlow>
<responseFlow>
<handler type="log"/>
</responseFlow>
</globalConfiguration>
<transport name="http"
pivot="java:org.apache.axis.transport.http.HTTPSender"/>
<transport name="local"
pivot="java:org.apache.axis.transport.local.LocalSender"/>
</deployment>
The handler that you reference here, must also be in the classpath.
Good luck,
Jan.
-----Mensaje original-----
De: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Enviado el: jueves, 04 de diciembre de 2003 11:44
Para: [EMAIL PROTECTED]
Asunto: Client handler
Hello
I have a simple servlet (not a web service) deployed on tomcat, it works
like a normal servlet : receveiving http request and sending http response.
But this servlet also have to invoke an axis webservice to get some
information : no problem with that : it works !
The problem start here : I would like to define an handler on the client
side : on the servlet.
I think there's something to do with client-config.wsdd but I don't
understand how it works, where it's located....
Can somebody explain me how to do that ?
Thanks
Valerie