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 Jonathan Schilling <jl...@sco.com> on 2005/12/15 23:31:00 UTC

how to find web service classes at alternate place

I have an existing webapp deployed, with methods I want to expose 
as web services.  This I have done per the instructions in
http://ws.apache.org/axis/java/install.html#AdvancedInstallationAddingAxisToYour
OwnWebapp,
and it is working.  (Tomcat 5.0.28, Axis 1.2.)

However, a few of this existing webapp's classes are not located
at the normal webapps/app-name/WEB-INF/classes/ place, but rather
are rooted in webapps/app-name/WEB-INF/something/otherthing/,
and are loaded into the webapp via the webapp's own classloader.

I want to expose methods from those classes as web services as well,
but Axis isn't finding them, since they are not in the expected directory.  
Due to the internal architecture of the webapp, I can't 
move them into one of the places Tomcat normally knows about.
Is there some way of telling Axis and/or Tomcat where they are?  

Is this possible somehow?  By extending Tomcat's or Axis' classloader?
Or is this inherently not going to work?  

Thanks for any insight ...

Jonathan Schilling


Re: how to find web service classes at alternate place

Posted by Jason Cwik <bi...@gmail.com>.
Or I guess you could use axis 2 and deploy your services in .aar files.

On 12/16/05, Jason Cwik <bi...@gmail.com> wrote:
>
> The only way I can think about doing this would be to hack the source for
> AxisServlet and have it initialize all of the axis code through a custom
> classloader.
>
> On Thu, 15 Dec 2005 17:31 EST, Jonathan Schilling <jl...@sco.com> wrote:
> >
> > I have an existing webapp deployed, with methods I want to expose
> > as web services.  This I have done per the instructions in
> >
> > http://ws.apache.org/axis/java/install.html#AdvancedInstallationAddingAxisToYour
> > OwnWebapp,
> > and it is working.  (Tomcat 5.0.28, Axis 1.2.)
> >
> > However, a few of this existing webapp's classes are not located
> > at the normal webapps/app-name/WEB-INF/classes/ place, but rather
> > are rooted in webapps/app-name/WEB-INF/something/otherthing/,
> > and are loaded into the webapp via the webapp's own classloader.
> >
> > I want to expose methods from those classes as web services as well,
> > but Axis isn't finding them, since they are not in the expected
> > directory.
> > Due to the internal architecture of the webapp, I can't
> > move them into one of the places Tomcat normally knows about.
> > Is there some way of telling Axis and/or Tomcat where they are?
> >
> > Is this possible somehow?  By extending Tomcat's or Axis' classloader?
> > Or is this inherently not going to work?
> >
> > Thanks for any insight ...
> >
> > Jonathan Schilling
> >
> >
>

Re: how to find web service classes at alternate place

Posted by Jason Cwik <bi...@gmail.com>.
The only way I can think about doing this would be to hack the source for
AxisServlet and have it initialize all of the axis code through a custom
classloader.

On Thu, 15 Dec 2005 17:31 EST, Jonathan Schilling <jl...@sco.com> wrote:
>
> I have an existing webapp deployed, with methods I want to expose
> as web services.  This I have done per the instructions in
>
> http://ws.apache.org/axis/java/install.html#AdvancedInstallationAddingAxisToYour
> OwnWebapp,
> and it is working.  (Tomcat 5.0.28, Axis 1.2.)
>
> However, a few of this existing webapp's classes are not located
> at the normal webapps/app-name/WEB-INF/classes/ place, but rather
> are rooted in webapps/app-name/WEB-INF/something/otherthing/,
> and are loaded into the webapp via the webapp's own classloader.
>
> I want to expose methods from those classes as web services as well,
> but Axis isn't finding them, since they are not in the expected directory.
> Due to the internal architecture of the webapp, I can't
> move them into one of the places Tomcat normally knows about.
> Is there some way of telling Axis and/or Tomcat where they are?
>
> Is this possible somehow?  By extending Tomcat's or Axis' classloader?
> Or is this inherently not going to work?
>
> Thanks for any insight ...
>
> Jonathan Schilling
>
>