You are viewing a plain text version of this content. The canonical link for it is here.
Posted to soap-user@ws.apache.org by "Gill, John" <Jo...@tgslc.org> on 2003/08/26 22:48:50 UTC

Multiple Deployment problems

I know I'm doing this wrong, but I can't seem to find a good description of
how to do it right.

What I'm trying to do is deploy two different soap services within the same
web app, where the two different services are in different classes.  Am I
out of luck? Or just not trying correctly?  

<isd:service xmlns:isd="http://xml.apache.org/xml-soap/deployment"
             id="urn:WSServer">
  <isd:provider type="java" scope="Request" methods="SubmitWS">
    <isd:java class="org.one.ws.server" static="true"/>
  </isd:provider>  
  <isd:provider type="java" scope="Request" methods="SubmitWS_2.0">
    <isd:java class="org.one.ws2.server" static="true"/>
  </isd:provider>

</isd:service>


Re: Trouble with BadTargetObjectURI / ClassNotFoundException

Posted by Scott Nichol <sn...@scottnichol.com>.
Check for spurious soap.jar, such as soap.jar in $JAVA_HOME/jre/lib/ext or in a catalina.[sh|bat] classpath.  If the Apache SOAP classes get loaded from outside the webapp, they cannot load the service classes from the webapp.

Scott Nichol

Do not send e-mail directly to this e-mail address,
because it is filtered to accept only mail from
specific mail lists.
----- Original Message ----- 
From: "Malte Kempff" <ke...@medicalcolumbus.de>
To: <so...@ws.apache.org>
Sent: Wednesday, August 27, 2003 12:45 PM
Subject: AW: Trouble with BadTargetObjectURI / ClassNotFoundException


> Hi Scott,
> thanks for your reply. The thing is, that we did it as you have said, but we
> got the  BadTargetObjectURI / ClassNotFoundException. The usual Soap-tests
> worked fine like they are to be read in the soap-docs.
> The  $CATALINA_HOME/webapps/soap/WEB-INF/lib] containes the needed .jar's,
> so it is not clear to me why the class holding the RPCs is not found.
> 
> 
> Malte
> 
> -----Ursprüngliche Nachricht-----
> Von: Scott Nichol [mailto:snicholnews@scottnichol.com]
> Gesendet: Mittwoch, 27. August 2003 17:14
> An: soap-user@ws.apache.org
> Betreff: Re: Trouble with BadTargetObjectURI / ClassNotFoundException
> 
> 
> Here is what I typically do.
> 
> 1. Stop Tomcat.
> 
> 2. Manually explode soap.war into $CATALINA_HOME/webapps/soap.  I do it
> manually even though Tomcat will do the same thing if soap.war is placed in
> $CATALINA_HOME/webapps, because I also add/change files in
> $CATALINA_HOME/webapps/soap/WEB-INF/[classes|lib], which is not supported on
> all servlet containers when you let them explode the .war for you.
> 
> 3. Put my service classes and jars into
> $CATALINA_HOME/webapps/soap/WEB-INF/[classes|lib].
> 
> 4. Start Tomcat.
> 
> 5. Deploy services.
> 
> Scott Nichol
> 
> Do not send e-mail directly to this e-mail address,
> because it is filtered to accept only mail from
> specific mail lists.
> ----- Original Message -----
> From: "Malte Kempff" <ke...@medicalcolumbus.de>
> To: <so...@ws.apache.org>
> Sent: Wednesday, August 27, 2003 6:36 AM
> Subject: Trouble with BadTargetObjectURI / ClassNotFoundException
> 
> 
> > Hello,
> > I have read a lot about that Problem, but in my perticular situation I did
> > not find a solution that works.
> > Soap was deployed by putting the soap.war into tomcats webapps-directory.
> > In one try there there was no enty in the server.xml and we got the
> > Server.BadTagetObjectURI with the ClassNotFoundException about the class
> > containing the soap-rpcs, even the jar-files neded are in teh web-inf/lib
> > directory.
> > When we put in a xml-statement in the server.xml of tomcat we must have
> got
> > an Exceptionmessage
> > like this      "Error opening socket:", "Connection refused:" or that
> > "java.net.NoRouteToHostException"
> > because the programm catches these messages assuming proxy-parameters have
> > to be setup and comes up with a dialog to enter them.
> > My question here is which of those two installations is on the futher way
> of
> > working corectly?
> > does soap first recognice a connectiontrouble or does it first recognice
> > that the serving class is not found?
> >
> > thanks in advance
> >
> > Malte
> >
> >
> >
> 
> 
> 

AW: Trouble with BadTargetObjectURI / ClassNotFoundException

Posted by Malte Kempff <ke...@medicalcolumbus.de>.
Hi Scott,
thanks for your reply. The thing is, that we did it as you have said, but we
got the  BadTargetObjectURI / ClassNotFoundException. The usual Soap-tests
worked fine like they are to be read in the soap-docs.
The  $CATALINA_HOME/webapps/soap/WEB-INF/lib] containes the needed .jar's,
so it is not clear to me why the class holding the RPCs is not found.


Malte

-----Ursprüngliche Nachricht-----
Von: Scott Nichol [mailto:snicholnews@scottnichol.com]
Gesendet: Mittwoch, 27. August 2003 17:14
An: soap-user@ws.apache.org
Betreff: Re: Trouble with BadTargetObjectURI / ClassNotFoundException


Here is what I typically do.

1. Stop Tomcat.

2. Manually explode soap.war into $CATALINA_HOME/webapps/soap.  I do it
manually even though Tomcat will do the same thing if soap.war is placed in
$CATALINA_HOME/webapps, because I also add/change files in
$CATALINA_HOME/webapps/soap/WEB-INF/[classes|lib], which is not supported on
all servlet containers when you let them explode the .war for you.

3. Put my service classes and jars into
$CATALINA_HOME/webapps/soap/WEB-INF/[classes|lib].

4. Start Tomcat.

5. Deploy services.

Scott Nichol

Do not send e-mail directly to this e-mail address,
because it is filtered to accept only mail from
specific mail lists.
----- Original Message -----
From: "Malte Kempff" <ke...@medicalcolumbus.de>
To: <so...@ws.apache.org>
Sent: Wednesday, August 27, 2003 6:36 AM
Subject: Trouble with BadTargetObjectURI / ClassNotFoundException


> Hello,
> I have read a lot about that Problem, but in my perticular situation I did
> not find a solution that works.
> Soap was deployed by putting the soap.war into tomcats webapps-directory.
> In one try there there was no enty in the server.xml and we got the
> Server.BadTagetObjectURI with the ClassNotFoundException about the class
> containing the soap-rpcs, even the jar-files neded are in teh web-inf/lib
> directory.
> When we put in a xml-statement in the server.xml of tomcat we must have
got
> an Exceptionmessage
> like this      "Error opening socket:", "Connection refused:" or that
> "java.net.NoRouteToHostException"
> because the programm catches these messages assuming proxy-parameters have
> to be setup and comes up with a dialog to enter them.
> My question here is which of those two installations is on the futher way
of
> working corectly?
> does soap first recognice a connectiontrouble or does it first recognice
> that the serving class is not found?
>
> thanks in advance
>
> Malte
>
>
>



Re: Trouble with BadTargetObjectURI / ClassNotFoundException

Posted by Scott Nichol <sn...@scottnichol.com>.
Here is what I typically do.

1. Stop Tomcat.

2. Manually explode soap.war into $CATALINA_HOME/webapps/soap.  I do it manually even though Tomcat will do the same thing if soap.war is placed in $CATALINA_HOME/webapps, because I also add/change files in $CATALINA_HOME/webapps/soap/WEB-INF/[classes|lib], which is not supported on all servlet containers when you let them explode the .war for you.

3. Put my service classes and jars into $CATALINA_HOME/webapps/soap/WEB-INF/[classes|lib].

4. Start Tomcat.

5. Deploy services.

Scott Nichol

Do not send e-mail directly to this e-mail address,
because it is filtered to accept only mail from
specific mail lists.
----- Original Message ----- 
From: "Malte Kempff" <ke...@medicalcolumbus.de>
To: <so...@ws.apache.org>
Sent: Wednesday, August 27, 2003 6:36 AM
Subject: Trouble with BadTargetObjectURI / ClassNotFoundException


> Hello,
> I have read a lot about that Problem, but in my perticular situation I did
> not find a solution that works.
> Soap was deployed by putting the soap.war into tomcats webapps-directory.
> In one try there there was no enty in the server.xml and we got the
> Server.BadTagetObjectURI with the ClassNotFoundException about the class
> containing the soap-rpcs, even the jar-files neded are in teh web-inf/lib
> directory.
> When we put in a xml-statement in the server.xml of tomcat we must have got
> an Exceptionmessage
> like this      "Error opening socket:", "Connection refused:" or that
> "java.net.NoRouteToHostException"
> because the programm catches these messages assuming proxy-parameters have
> to be setup and comes up with a dialog to enter them.
> My question here is which of those two installations is on the futher way of
> working corectly?
> does soap first recognice a connectiontrouble or does it first recognice
> that the serving class is not found?
> 
> thanks in advance
> 
> Malte
> 
> 
> 

Trouble with BadTargetObjectURI / ClassNotFoundException

Posted by Malte Kempff <ke...@medicalcolumbus.de>.
Hello,
I have read a lot about that Problem, but in my perticular situation I did
not find a solution that works.
Soap was deployed by putting the soap.war into tomcats webapps-directory.
In one try there there was no enty in the server.xml and we got the
Server.BadTagetObjectURI with the ClassNotFoundException about the class
containing the soap-rpcs, even the jar-files neded are in teh web-inf/lib
directory.
When we put in a xml-statement in the server.xml of tomcat we must have got
an Exceptionmessage
like this      "Error opening socket:", "Connection refused:" or that
"java.net.NoRouteToHostException"
because the programm catches these messages assuming proxy-parameters have
to be setup and comes up with a dialog to enter them.
My question here is which of those two installations is on the futher way of
working corectly?
does soap first recognice a connectiontrouble or does it first recognice
that the serving class is not found?

thanks in advance

Malte



Re: Multiple Deployment problems

Posted by Scott Nichol <sn...@scottnichol.com>.
John,

Each class containing service methods must have a unique namespace (the id attribute of isd:service).  This means you must deploy your 2 separate classes as separate namespaces within the webapp, e.g. you should use 2 deployment descriptors, such as

<isd:service xmlns:isd="http://xml.apache.org/xml-soap/deployment"
             id="urn:WSServer">
  <isd:provider type="java" scope="Request" methods="SubmitWS">
    <isd:java class="org.one.ws.server" static="true"/>
  </isd:provider>  
</isd:service>

<isd:service xmlns:isd="http://xml.apache.org/xml-soap/deployment"
             id="urn:WS2Server">
  <isd:provider type="java" scope="Request" methods="SubmitWS_2.0">
    <isd:java class="org.one.ws2.server" static="true"/>
  </isd:provider>
</isd:service>


Scott Nichol

Do not send e-mail directly to this e-mail address,
because it is filtered to accept only mail from
specific mail lists.
----- Original Message ----- 
From: "Gill, John" <Jo...@tgslc.org>
To: <so...@ws.apache.org>
Sent: Tuesday, August 26, 2003 4:48 PM
Subject: Multiple Deployment problems


> I know I'm doing this wrong, but I can't seem to find a good description of
> how to do it right.
> 
> What I'm trying to do is deploy two different soap services within the same
> web app, where the two different services are in different classes.  Am I
> out of luck? Or just not trying correctly?  
> 
> <isd:service xmlns:isd="http://xml.apache.org/xml-soap/deployment"
>              id="urn:WSServer">
>   <isd:provider type="java" scope="Request" methods="SubmitWS">
>     <isd:java class="org.one.ws.server" static="true"/>
>   </isd:provider>  
>   <isd:provider type="java" scope="Request" methods="SubmitWS_2.0">
>     <isd:java class="org.one.ws2.server" static="true"/>
>   </isd:provider>
> 
> </isd:service>
> 
>