As the error message you see says, the problem is not the
targetObjectURI, it is the SOAPAction.  The SOAPAction is specified as a
parameter to call.invoke or SOAPTransport.send.

Scott Nichol

----- Original Message -----
From: "Sauquet Dominique" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, December 17, 2002 1:14 PM
Subject: Propblem with SOAPAction not correct while invoking a Web
service


I tried to access the Global Weather service that looks great.
Unfortunately, I got the following error :

After  extractFromEnvelope :

[Header=null] [methodName=null]
[targetObjectURI=null] [encodingStyleURI=null]
[SOAPContext=[Parts={[cid:null type: text/xml enc: null]}] multiRefs: 0
deserializedMultiRefs: 0] [fault=[Attributes={}] [faultCode=
SOAP-ENV:Client.MessageFormat]
[faultString=SOAPAction is not correct for the ta
rget web service method:  Got "", expected
"capeconnect:GlobalWeather:StationInf
o#isValidCode"]
[faultActorURI=capeconnect:dispatch:dispatcher]
[DetailEntries=
[(0)=<cc2:exception
xmlns:cc2="http://www.capeclear.com/soapfaultdetail";>
<type xsi:type="xsd:string"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance
">com.capeclear.capeconnect.api.exception.CCException</type><value>
<detailMessage xsi:type="xsd:string"
xmlns:xsi="http://www.w3.org/2001/XMLSchema
-instance">SOAPAction is not correct for the target web service method:
Got
&qu
ot;&quot;, expected
&quot;capeconnect:GlobalWeather:StationInfo#isValidCode&quot
;</detailMessage><nested xsi:nil="true"
xmlns:xsi="http://www.w3.org/2001/XMLSch
ema-instance"/><errorCode>

My code is based on the getTemp example of the samples of SOAP withe the
following
modifications.

URL url = new URL("http://live.capescience.com:80/ccx/GlobalWeather";);

Call call = new Call();
call.setSOAPTransport(st);
call.setTargetObjectURI("capeconnect:GlobalWeather:StationInfo");
call.setMethodName("isValidCode");
call.setEncodingStyleURI(Constants.NS_URI_SOAP_ENC);

Vector params = new Vector();
params.addElement(new Parameter("code", String.class,"JFK", null));
call.setParams(params);

I also tried (and many others) :
call.setTargetObjectURI("capeconnect:GlobalWeather:GlobalWeather");
call.setMethodName("getWeatherReport");

Thanks a lot
Dominique
ps : you will get info at
http://live.capescience.com/GlobalWeather/index.html
or
http://www.capescience.com/webservices/globalweather/index.shtml


> Dominique Sauquet
> Direction des Moyens Informatiques
> Tel : 01 46 84 13 12
> <mailto:[EMAIL PROTECTED]>
>
> Prosodie
> 150, rue Galliéni
> 92100 Boulogne
> <http://www.prosodie.com/>
>
>
>

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>



--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to