I am not sure what the issue is, but here are some things to verify:
Is the service using https? Is the client pointing to endpoint with correct
protocol? If you use https, the client needs to register https protocol:
static {
org.globus.axis.util.Util.registerTransport();
}
Rachana
> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf
> Of Lin Wan
> Sent: Saturday, January 26, 2008 3:27 AM
> To: [email protected]
> Subject: [gt-user] Can Grid Service invoke Standard Web Service?
>
> Dear all,
>
> I want to use Grid Service to wrap some standard Web Services,
> so I write some samples.
> First of all, I invoked a standard web service:
> ---------------------------------------------------------------------
> public static void main(String[] args) {
> String endpoint = " http://www.wopos.com/webservice/weather.asmx";
> Service service = new Service();
> Call call;
> try {
> call = (Call) service.createCall();
>
> try {
> call.setTargetEndpointAddress( new java.net.URL(endpoint) );
> } catch (MalformedURLException e) {
> // TODO Auto-generated catch block
> e.printStackTrace();
> }
>
> call.setSOAPActionURI( " http://tempuri.org/HelloWopos" );
> call.setEncodingStyle( "
> http://schemas.xmlsoap.org/soap/encoding/" );
>
> call.setOperationName("HelloWorld");
> call.setReturnType( XMLType.XSD_STRING);
> call.addParameter( "op1", XMLType.XSD_INT, ParameterMode.IN );
> call.setUseSOAPAction(true);
>
> try {
> String str = (String)call.invoke(new Object[]{1});
> System.out.print(str);
> } catch (RemoteException e) {
> // TODO Auto-generated catch block
> e.printStackTrace();
> }
>
>
> } catch (ServiceException e) {
> // TODO Auto-generated catch block
> e.printStackTrace();
> }
> }
> --------------------------------------------------------------------------
> ----------
> The invoking result is successfull
>
> Then I wrapped this web service with globus Grid service and build the
> service,deployed the service like the "math" sample of the gt4
> programming guide.
>
> When I tried to use the client to invoke the grid service, it failed:
>
> AxisFault
> faultCode: {http://xml.apache.org/axis/}HTTP
> faultSubcode:
> faultString: (400)Bad Request
> faultActor:
> faultNode:
> faultDetail:
> {}:return code: 400
>
> {http://xml.apache.org/axis/}HttpErrorCode:400
>
> (400)Bad Request
> at
> org.apache.axis.transport.http.HTTPSender.readFromSocket(HTTPSender.j
> ava:692)
> at
> org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:141)
>
> at
> org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrateg
> y.java:32)
> at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
> at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
> at org.apache.axis.client.AxisClient.invoke(AxisClient.java:165)
> at org.apache.axis.client.Call.invokeEngine(Call.java:2727)
> at org.apache.axis.client.Call.invoke(Call.java:2710)
> at org.apache.axis.client.Call.invoke(Call.java:2386)
> at org.apache.axis.client.Call.invoke(Call.java:2309)
> at org.apache.axis.client.Call.invoke(Call.java:1766)
> at
> net.mapgis.www.mds.MapgisDataServiceSoapStub.getMap(MapgisDataService
> SoapStub.java:586)
> at
> org.globus.examples.services.core.first.impl.WMS.GetMap(WMS.java:102)
>
> at
> org.globus.examples.services.core.first.impl.FirstMapService.execute(
> FirstMapService.java:53)
> at
> org.globus.examples.services.core.first.impl.FirstMapService.getMapRP
> (FirstMapService.java:62)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
> java:39)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
> sorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:597)
> at
> org.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.j
> ava:384)
> at
> org.globus.axis.providers.RPCProvider.invokeMethodSub(RPCProvider.jav
> a:107)
> at
> org.globus.axis.providers.RPCProvider.invokeMethod(RPCProvider.java:9
> 0)
> at
> org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider
> .java:281)
> at
> org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:
> 319)
> at
> org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrateg
> y.java:32)
> at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
> at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
> at
> org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:450
> )
> at org.apache.axis.server.AxisServer.invoke(AxisServer.java:285)
> at
> org.globus.wsrf.container.ServiceThread.doPost(ServiceThread.java:664
> )
> at
> org.globus.wsrf.container.ServiceThread.process(ServiceThread.java:38
> 2)
> at
> org.globus.wsrf.container.ServiceThread.run(ServiceThread.java:291)
>
>
> ------------------------------------------
>
> Is there any problem with apache Axis of GT4?
>
> ------------------
> Lin Wan
> 2008-1-25