Re: Log outgoing/incoming messages w/ Client Handler
Hi Darrin, You can use the axis LogHander in your wsdd. If you add it to your requestFlow and repsonseFlow it will log the incoming and outgoing messages from your service. Hope this helps. Richard. Dowell, Darrin wrote: I have the Axis generated client code (using WSDL2Java) and I'd like to use an Axis handler to intercept request/response messages to log them. Static void main(String[] args){ MyServiceLocator serviceLocator = new MyServiceLocator(); serviceLocator.setServiceSoapEndpointAddress("http://myservice.com/";); port = serviceLocator.getMyServiceSoap(); String response = getPort().getLeadList(request); } Is there a way to extend one of the Axis classes to log my messages? I don't have the option of doing JaxRPC or using the WSDD file option. I'm looking for how to code the handler to log the message and how to tie the handler into my calling of the service above. Thanks in advance Darrin Dowell
Re: Log outgoing/incoming messages w/ Client Handler
Programatically it would look like: java.util.List list = svc.getHandlerRegistry().getHandlerChain(portQN); list.add(new javax.xml.rpc.handler.HandlerInfo(ClientHandler.class,this.handlerConfig,null)); Should help googling. iksrazal --- "Dowell, Darrin" <[EMAIL PROTECTED]> wrote: > > > > I have the Axis generated client code (using > WSDL2Java) and I'd like to use > an Axis handler to intercept request/response > messages to log them. > > Static void main(String[] args){ > > MyServiceLocator serviceLocator = new > MyServiceLocator(); > > serviceLocator.setServiceSoapEndpointAddress("http://myservice.com/";); > port = serviceLocator.getMyServiceSoap(); > String response = getPort().getLeadList(request); > } > > Is there a way to extend one of the Axis classes to > log my messages? I > don't have the option of doing JaxRPC or using the > WSDD file option. > > I'm looking for how to code the handler to log the > message and how to tie > the handler into my calling of the service above. > > Thanks in advance > > > Darrin Dowell > > > "None are more hopelessly enslaved than those who falsely believe they are free. -- Goethe" __ Yahoo! Mail - PC Magazine Editors' Choice 2005 http://mail.yahoo.com
Re: Log outgoing/incoming messages w/ Client Handler
You can put a client-side handler in with the HandlerRegistry programmatically - without an wsdd. This question comes up frequently so try googling or searching the list - "iksrazal HandlerRegistry" may help as I believe we had the discussion recently. HTH, iksrazal --- "Dowell, Darrin" <[EMAIL PROTECTED]> wrote: > > > > I have the Axis generated client code (using > WSDL2Java) and I'd like to use > an Axis handler to intercept request/response > messages to log them. > > Static void main(String[] args){ > > MyServiceLocator serviceLocator = new > MyServiceLocator(); > > serviceLocator.setServiceSoapEndpointAddress("http://myservice.com/";); > port = serviceLocator.getMyServiceSoap(); > String response = getPort().getLeadList(request); > } > > Is there a way to extend one of the Axis classes to > log my messages? I > don't have the option of doing JaxRPC or using the > WSDD file option. > > I'm looking for how to code the handler to log the > message and how to tie > the handler into my calling of the service above. > > Thanks in advance > > > Darrin Dowell > > > "None are more hopelessly enslaved than those who falsely believe they are free. -- Goethe" __ Yahoo! Mail - PC Magazine Editors' Choice 2005 http://mail.yahoo.com