• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Tim Cooke
  • Liutauras Vilda
  • Jeanne Boyarsky
Sheriffs:
  • Paul Clapham
  • Rob Spoor
  • Junilu Lacar
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Piet Souris
  • Carey Brown
Bartenders:

javax.rpc.call problem

 
Ranch Hand
Posts: 57
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hello...

i have written a client programme for calling webservices...method. ..and kept axix.jar and soap.jar..in the classpath but..the programme is not compling saying...can't axcess javax.xml.rpc.call;

please tell what might be the problem..

import org.apache.axis.client.Call;
import org.apache.axis.client.Service;
import javax.xml.namespace.QName;

public class TestClient {
public static void main(String [] args) {
try {
String endpoint = "http://100.0.1.1/Apple/OpBilling/Billing.asmx";

// "http://ws.apache.org:5049/axis/services/echo";


Service service = new Service();
Call call = (Call) service.createCall();

call.setTargetEndpointAddress( new java.net.URL(endpoint) );
call.setOperationName(new QName("http://tempuri.org/", "ChargeUser"));
//targetNamespace= http://tempuri.org/

String ret = (String) call.invoke( new Object[] { "9866655320","1","sebtain","imi@123" } );

System.out.println("sending four parameters mobileno,rs 1,sebtain,password...output is "+ret);
} catch (Exception e) {
System.err.println(e.toString());
}
}
}

Thanks to all...
 
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It looks to me like a version problem. Axis2 does not have that class but Axis1.4 does have org.apache.axis.client.Call.

Looks like Axis 2 made some major changes.

Bill
 
aman hindustani
Ranch Hand
Posts: 57
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
thanks for you reply...

i wrote a new code which compiled properly while in execution it is throwing ..exception..can you please help me out.



please help me out..
 
William Brogden
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Server did not recognize the value of HTTP Header SOAPAction: .



If this was my problem I would use TCPMON (comes with axis) to trap the exact text of the SOAP request. I would compare the SOAPAction header value to that specified by the service.

Bill
 
aman hindustani
Ranch Hand
Posts: 57
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hello to all..

please ..help me in fixing this ....

Server did not recognize the value of HTTP Header SOAPAction..
what i need to add in my code so that this Exception will not be thrown....

Thanks,
Aman
 
reply
    Bookmark Topic Watch Topic
  • New Topic