You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Ani Marius <bu...@yahoo.com> on 2005/05/08 14:43:32 UTC

Providers and Handlers

Hi!
I've created a custom provider for my diploma project.
It works fine, its purpose is to execute the content
of a XML file (some kind of ws orchestration)...now, I
want to do the following : when a client invokes a web
service, if the requested ws is not already deployed,
i will search for the wsdl file in a already known
directory and deploy the ws automatically (i created a
class Deployer who does it, and works fine)...In order
to achieve this mechanism, before the request reaches
the provider, the requested ws must be deployed...so,
I implemented a handler (CustomHandler) which takes
the name of the target service and if it is not
deployed, it will deploy it using the Deployer class.
I did the remote debugging using Intellij Idea and
after the method deploy of the Deployer class was
called, the new ws was deployed.
But, when reaching the service method of the Servlet
class, I get the error :
" The AXIS engine could not find a target service to
invoke!  targetService is Book", altough the Deployer
class deployed the Book ws. The Book was also deployed
setting the provider as my custom provider.
Anyway, in the deploy method, if I say :
MessageContext msgCtx =
MessageContext.getCurrentContext();
        msgCtx.setService(soapService);
,
the problem now is that the request is not forwarded
to the provider anymore.

In the WSDD file, I wrote :
<transport name="http">
  <requestFlow>
   <handler type="URLMapper"/>
   <handler type="CustomHandler"/>
   <handler
type="java:org.apache.axis.handlers.http.HTTPAuthHandler"/>
  </requestFlow>
 </transport>

where CustomHandler is my handler that extends
BasicHandler.



Please help me, because I have little time to finish
it.
Thanx.

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com