Women in Technology

Hear us Roar

  Using SOAP with Tomcat
Subject:   SOAP
Date:   2002-03-07 12:31:39
From:   moranc
Arghhh! I did everything correctly! Everything worked until I tried to test the client. Then I got this:

The call failed:
Fault Code = SOAP-ENV:Server.BadTargetObjectURI
Fault String = Unable to resolve target object: onjava.CalcService


Main Topics Oldest First

Showing messages 1 through 7 of 7.

  • SOAP
    2004-03-22 20:22:22  hector_durante [View]

    I fix it when i put the server program CalcService.class into the directory TOMCAT_HOME\shared\classes\onjava instead of TOMCAT_HOME\webapps\soap\WEB-INF\classes\onjava\
    and execute java CalcClient 90 98 into the directory TOMCAT_HOME\webapps\soap\WEB-INF\classes\
    note.- the CalcClient.class must be in TOMCAT_HOME\webapps\soap\WEB-INF\classes\onjava\
  • Putting the service, where ? and OS X
    2003-06-24 13:25:24  anonymous2 [View]

    Have the same problem :


    But i don´t like the idea of putting my services inside the soap.war package.

    InRedHat i just put the service on the general classpath of the machine, and it gets called.

    Question: Where is the PROPER place to put the code so tomcat can "see" it ??

    And: Classpaths are samewhat strange in OS X, theres a Extensions link where we should put the programs similar to the JAVA_HOME/jre/lib/ext concept. But i don´t know if Tomcat can see those classes in OS X ...

    Anybody has any clue on this particular one ??

    greetings everybody, from the other side of the world .. !
  • SOAP
    2002-09-10 09:22:29  anonymous2 [View]

    You have to place your classes in sub directories, under Tomcat/classes, relating to their packages.
  • SOAP
    2002-08-22 09:03:52  lelo [View]


    I do step by step and have the same problem, how can i resolve
    thank you

    "The call failed:
    Fault Code = SOAP-ENV:Server.BadTargetObjectURI
    Fault String = Unable to resolve target object: onjava.CalcService"
  • SOAP-ENV:Server.BadTargetObjectURI
    2002-08-01 11:06:25  majidbakhsh [View]

    I too have this reoccurring problem – Have any of the individuals who have experienced this problem found a solution yet?

    I have carefully followed through O'Reilly's “Hello SOAP!” example step by step.

    I deploy the Client Code without any problems as my service shows up on the list of deployed services:

    Typing “java org.apache.soap.server.ServiceManagerClient http://localhost:8080/soap/servlet/rpcrouter list” into the command-line yields:

    Deployed Services:

    However, when I try to test the client I get the following error:

    Hello SOAP Client
    Fault Occurred (details follow):
    Fault Code: SOAP-ENV:Server.BadTargetObjectURI
    Fault String: Unable to resolve target object:
    Fault Occurred. No greeting for you!

    After this I modify the client code to use port 8070 so that I may use the TCPTunnelGui tool to view my actual SOAP conversation.

    To invoke this TCPTunnelGui Tool I type the following into the command line:

    “java org.apache.soap.util.net.TcpTunnelGui 8070 localhost 8080”

    I then try to test my client again and get the following SOAP messages within the TCPTunnelGui tool

    From localhost:8070 :

    POST /soap/servlet/rpcrouter HTTP/1.0


    Content-Type: text/xml; charset=utf-8

    Content-Length: 464

    SOAPAction: ""

    <?xml version='1.0' encoding='UTF-8'?>

    <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">


    <ns1:sayHello xmlns:ns1="urn:examples:HelloService" SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">

    <firstName xsi:type="xsd:string">maj</firstName>




    & From localhost:8080 :

    HTTP/1.0 500 Internal Server Error

    Content-Type: text/xml; charset=utf-8

    Content-Length: 486

    Set-Cookie: JSESSIONID=trk0yz6te1;Path=/soap

    Date: Thu, 01 Aug 2002 17:23:16 GMT

    Server: Tomcat Web Server/3.3.1 Final ( JSP 1.1; Servlet 2.2 )

    <?xml version='1.0' encoding='UTF-8'?>

    <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">




    <faultstring>Unable to resolve target object: </faultstring>





    Any insights into this problem would be greatly appreciated!


  • SOAP
    2002-06-14 13:51:36  thebpc [View]

    I have the same problem here.
    couls you please run the:
    java org.apache.soap.server.ServiceManagerClient
    http://localhost:8080/apache-soap/servlet/rpcrouter query urn:onserver

    and let me know what you get, I see this as a general instalation problem and I want to check on this.
    Thanks Boris
  • SOAP
    2002-05-21 06:50:44  ssdfg [View]

    I have the simular Problem. On a Windows NT machine, and the same envoirement as they descrieb in the text.


    > java onjava.CalcClient 98 90
    > The call failed:
    > Fault Code = SOAP-ENV:Server
    > Fault String = service 'urn:onjavaserver'

    But if I check the list:
    > java org.apache.soap.server.ServiceManagerClient http://localhost:8080/soap/servlet/rpcrouter list
    > Deployed Services:
    > urm:onjavaserver