good news before the weekend: I got your process working! Here what i did:
#1. use lower case file extensions #2. set to DEBUG the log4j categories org.apache.ode.axis2 and httpclient in $bpms-server/var/log/log4j.properties (do it at the very bottom of the file to make sure the log level is not overridden) #3. start the process. Exceptions all over the place in the server console or in $bpms-server/var/log/bpms.log but you'll see the following message: 16:49:23,288 DEBUG [HttpMethodConverter] Body received but not mapped to any part! Body= <?xml version="1.0"?> <ResultSet xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="urn:yahoo:maps" xsi:schemaLocation="urn:yahoo:maps http://api.local.yahoo.com/MapsService/V1/GeocodeResponse.xsd"><Result precision="street"><Latitude>37.785120</Latitude><Longitude>-122.454709</Longitude><Address>Parker Ave</Address><City>San Francisco</City><State>CA</State><Zip>94118</Zip><Country>US</Country></Result></ResultSet> Big, big hint!! Something might be wrong in the yahoo wsdl. The response body needs to be set in a message part. See my earlier message to Bill in this same thread. #4 edit the yahoo wsdl YahooGeocodeWSDL.wsdl, add the mime namespace, and change the output1 as follows: .../var/deploy/yahoo/processes.ode$diff YahooGeocodeWSDL.wsdl YahooGeocodeWSDL.wsdl.broken 4d3 < xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" 38,40c37 < <output name="output1"> < <mime:content type="text/xml" part="geoCoderResult"/> < </output> --- > <output name="output1"/> #5 redeploy the process #6 send a request, enjoy the process response: <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:Body> <odens:SOAPTriggerWSDLOperationResponse xmlns:odens=" http://j2ee.netbeans.org/wsdl/GeocoderBpelModule/SOAPTriggerWSDL"> <latitude>37.785120</latitude> <longitude/> </odens:SOAPTriggerWSDLOperationResponse> </soapenv:Body> </soapenv:Envelope> #7 celebrate! Have a good weekend! Alexis On Wed, Jul 8, 2009 at 2:40 AM, Ricardo Pereira <[email protected]>wrote: > Hello, > I have a very simple process that just invokes an REST external web service > from Yahoo (http://developer.yahoo.com/maps/rest/V1/geocode.html). > > When i run it on Netbeans it is very quick and returns the expected result > (the latitude and longitude that are returned in decimal and i convert to > string). > > When i deploy it on Apache ODE, it returns Timed Out. What am i doing > wrong? > > I've seen other posts but i din't find good answers to this (the only > answer > i found was to increase the time out variable but that isn't a solution). > > I paste here the necessary files. (i tried to send it in attach but it > returned an error so i paste them here). > > I really appreciate your help as quick as you can. > > Thanks > Ricardo > > ###################################################### > DEPLOY.XML > ###################################################### > > > <deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" > xmlns:pns=" > http://enterprise.netbeans.org/bpel/GeocoderBpelModule/GeocoderProcess" > xmlns:wns=" > http://j2ee.netbeans.org/wsdl/GeocoderBpelModule/SOAPTriggerWSDL" > xmlns:wnsYahooPL=" > http://j2ee.netbeans.org/wsdl/GeocoderBpelModule/YahooGeocodeWSDL"> > > <process name="pns:GeocoderProcess"> > <active>true</active> > <provide partnerLink="TriggerPL"> > <service name="wns:SOAPTriggerWSDLService" port="SOAPTriggerWSDLPort"/> > </provide> > <invoke partnerLink="YahooPL"> > <service name="wnsYahooPL:YahooGeocodeWSDLService" > port="YahooGeocodeWSDLPort"/> > </invoke> > </process> > </deploy> > > > ###################################################### > GeocoderProcess.BPEL > ###################################################### > > <?xml version="1.0" encoding="UTF-8"?> > <process > name="GeocoderProcess" > targetNamespace=" > http://enterprise.netbeans.org/bpel/GeocoderBpelModule/GeocoderProcess" > xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" > xmlns:xsd="http://www.w3.org/2001/XMLSchema" > xmlns:sxt=" > http://www.sun.com/wsbpel/2.0/process/executable/SUNExtension/Trace" > xmlns:sxed=" > http://www.sun.com/wsbpel/2.0/process/executable/SUNExtension/Editor" > xmlns:sxeh=" > http://www.sun.com/wsbpel/2.0/process/executable/SUNExtension/ErrorHandling > " > xmlns:tns=" > http://enterprise.netbeans.org/bpel/GeocoderBpelModule/GeocoderProcess" > xmlns:ns0="urn:yahoo:maps"> > <import namespace=" > http://j2ee.netbeans.org/wsdl/GeocoderBpelModule/YahooGeocodeWSDL" > location="YahooGeocodeWSDL.wsdl" importType=" > http://schemas.xmlsoap.org/wsdl/"/> > <import namespace=" > http://j2ee.netbeans.org/wsdl/GeocoderBpelModule/SOAPTriggerWSDL" > location="SOAPTriggerWSDL.wsdl" importType=" > http://schemas.xmlsoap.org/wsdl/ > "/> > <partnerLinks> > <partnerLink name="TriggerPL" xmlns:tns=" > http://j2ee.netbeans.org/wsdl/GeocoderBpelModule/SOAPTriggerWSDL" > partnerLinkType="tns:SOAPTriggerWSDL" > myRole="SOAPTriggerWSDLPortTypeRole"/> > <partnerLink name="YahooPL" xmlns:tns=" > http://j2ee.netbeans.org/wsdl/GeocoderBpelModule/YahooGeocodeWSDL" > partnerLinkType="tns:YahooGeocodeWSDL" > partnerRole="YahooGeocodeWSDLPortTypeRole"/> > </partnerLinks> > <variables> > <variable name="SOAPTriggerWSDLOperationOut" xmlns:tns=" > http://j2ee.netbeans.org/wsdl/GeocoderBpelModule/SOAPTriggerWSDL" > messageType="tns:SOAPTriggerWSDLOperationResponse"/> > <variable name="SOAPTriggerWSDLOperationIn" xmlns:tns=" > http://j2ee.netbeans.org/wsdl/GeocoderBpelModule/SOAPTriggerWSDL" > messageType="tns:SOAPTriggerWSDLOperationRequest"/> > <variable name="YahooGeocodeWSDLOperationOut" xmlns:tns=" > http://j2ee.netbeans.org/wsdl/GeocoderBpelModule/YahooGeocodeWSDL" > messageType="tns:YahooGeocodeWSDLOperationResponse"/> > <variable name="YahooGeocodeWSDLOperationIn" xmlns:tns=" > http://j2ee.netbeans.org/wsdl/GeocoderBpelModule/YahooGeocodeWSDL" > messageType="tns:YahooGeocodeWSDLOperationRequest"/> > </variables> > <sequence> > <receive name="Receive" createInstance="yes" partnerLink="TriggerPL" > operation="SOAPTriggerWSDLOperation" xmlns:tns=" > http://j2ee.netbeans.org/wsdl/GeocoderBpelModule/SOAPTriggerWSDL" > portType="tns:SOAPTriggerWSDLPortType" > variable="SOAPTriggerWSDLOperationIn"/> > <assign name="GetAddress"> > <copy> > <from variable="SOAPTriggerWSDLOperationIn" part="street"/> > <to variable="YahooGeocodeWSDLOperationIn" part="street"/> > </copy> > <copy> > <from variable="SOAPTriggerWSDLOperationIn" part="city"/> > <to variable="YahooGeocodeWSDLOperationIn" part="city"/> > </copy> > <copy> > <from variable="SOAPTriggerWSDLOperationIn" part="state"/> > <to variable="YahooGeocodeWSDLOperationIn" part="state"/> > </copy> > <copy> > <from>'ricardo.cpereira'</from> > <to variable="YahooGeocodeWSDLOperationIn" part="appid"/> > </copy> > </assign> > <invoke name="InvokeYahoo" partnerLink="YahooPL" > operation="YahooGeocodeWSDLOperation" xmlns:tns=" > http://j2ee.netbeans.org/wsdl/GeocoderBpelModule/YahooGeocodeWSDL" > portType="tns:YahooGeocodeWSDLPortType" > inputVariable="YahooGeocodeWSDLOperationIn" > outputVariable="YahooGeocodeWSDLOperationOut"/> > <assign name="SetResult"> > <copy> > > > > <from>string($YahooGeocodeWSDLOperationOut.geoCoderResult/ns0:Result/ns0:Latitude)</from> > <to variable="SOAPTriggerWSDLOperationOut" part="latitude"/> > </copy> > </assign> > <reply name="Reply" partnerLink="TriggerPL" > operation="SOAPTriggerWSDLOperation" xmlns:tns=" > http://j2ee.netbeans.org/wsdl/GeocoderBpelModule/SOAPTriggerWSDL" > portType="tns:SOAPTriggerWSDLPortType" > variable="SOAPTriggerWSDLOperationOut"/> > </sequence> > </process> > > > > ###################################################### > SOAPTriggerWSDL.WSDL > ###################################################### > > <?xml version="1.0" encoding="UTF-8"?> > <definitions name="SOAPTriggerWSDL" targetNamespace=" > http://j2ee.netbeans.org/wsdl/GeocoderBpelModule/SOAPTriggerWSDL" > xmlns="http://schemas.xmlsoap.org/wsdl/" > xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" > xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:tns=" > http://j2ee.netbeans.org/wsdl/GeocoderBpelModule/SOAPTriggerWSDL" > xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:soap=" > http://schemas.xmlsoap.org/wsdl/soap/"> > <types/> > <message name="SOAPTriggerWSDLOperationRequest"> > <part name="street" type="xsd:string"/> > <part name="city" type="xsd:string"/> > <part name="state" type="xsd:string"/> > </message> > <message name="SOAPTriggerWSDLOperationResponse"> > <part name="latitude" type="xsd:string"/> > <part name="longitude" type="xsd:string"/> > </message> > <portType name="SOAPTriggerWSDLPortType"> > <operation name="SOAPTriggerWSDLOperation"> > <input name="input1" > message="tns:SOAPTriggerWSDLOperationRequest"/> > <output name="output1" > message="tns:SOAPTriggerWSDLOperationResponse"/> > </operation> > </portType> > <binding name="SOAPTriggerWSDLBinding" > type="tns:SOAPTriggerWSDLPortType"> > <soap:binding style="rpc" transport=" > http://schemas.xmlsoap.org/soap/http"/> > <operation name="SOAPTriggerWSDLOperation"> > <soap:operation/> > <input name="input1"> > <soap:body use="literal" namespace=" > http://j2ee.netbeans.org/wsdl/GeocoderBpelModule/SOAPTriggerWSDL"/> > </input> > <output name="output1"> > <soap:body use="literal" namespace=" > http://j2ee.netbeans.org/wsdl/GeocoderBpelModule/SOAPTriggerWSDL"/> > </output> > </operation> > </binding> > <service name="SOAPTriggerWSDLService"> > <port name="SOAPTriggerWSDLPort" > binding="tns:SOAPTriggerWSDLBinding"> > <soap:address location=" > http://localhost:9090/ode/processes/SOAPTriggerWSDLService"/> > </port> > </service> > <plnk:partnerLinkType name="SOAPTriggerWSDL"> > <!-- A partner link type is automatically generated when a new port > type is added. Partner link types are used by BPEL processes. > In a BPEL process, a partner link represents the interaction between the > BPEL process and a partner service. Each partner link is associated with a > partner link type. > A partner link type characterizes the conversational relationship between > two services. The partner link type can have one or two roles.--> > <plnk:role name="SOAPTriggerWSDLPortTypeRole" > portType="tns:SOAPTriggerWSDLPortType"/> > </plnk:partnerLinkType> > </definitions> > > > ###################################################### > YahooGeocodeWSDL.WSDL > ###################################################### > > <?xml version="1.0" encoding="UTF-8"?> > <definitions name="YahooGeocodeWSDL" targetNamespace=" > http://j2ee.netbeans.org/wsdl/GeocoderBpelModule/YahooGeocodeWSDL" > xmlns="http://schemas.xmlsoap.org/wsdl/" > xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" > xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:tns=" > http://j2ee.netbeans.org/wsdl/GeocoderBpelModule/YahooGeocodeWSDL" > xmlns:ns="urn:yahoo:maps" xmlns:plnk=" > http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:http=" > http://schemas.xmlsoap.org/wsdl/http/"> > <types> > <xsd:schema targetNamespace=" > http://j2ee.netbeans.org/wsdl/GeocoderBpelModule/YahooGeocodeWSDL"> > <xsd:import namespace="urn:yahoo:maps" schemaLocation=" > http://local.yahooapis.com/MapsService/V1/GeocodeResponse.xsd"/> > </xsd:schema> > </types> > <message name="YahooGeocodeWSDLOperationRequest"> > <part name="appid" type="xsd:string"/> > <part name="street" type="xsd:string"/> > <part name="city" type="xsd:string"/> > <part name="state" type="xsd:string"/> > </message> > <message name="YahooGeocodeWSDLOperationResponse"> > <part name="geoCoderResult" element="ns:ResultSet"/> > </message> > <portType name="YahooGeocodeWSDLPortType"> > <operation name="YahooGeocodeWSDLOperation"> > <input name="input1" > message="tns:YahooGeocodeWSDLOperationRequest"/> > <output name="output1" > message="tns:YahooGeocodeWSDLOperationResponse"/> > </operation> > </portType> > <binding name="YahooGeocodeWSDLBinding" > type="tns:YahooGeocodeWSDLPortType"> > <http:binding verb="GET"/> > <operation name="YahooGeocodeWSDLOperation"> > <http:operation location=""/> > <input name="input1"> > <http:urlEncoded/> > </input> > <output name="output1"/> > </operation> > </binding> > <service name="YahooGeocodeWSDLService"> > <port name="YahooGeocodeWSDLPort" > binding="tns:YahooGeocodeWSDLBinding"> > <http:address location=" > http://local.yahooapis.com/MapsService/V1/geocode"/> > </port> > </service> > <plnk:partnerLinkType name="YahooGeocodeWSDL"> > <!-- A partner link type is automatically generated when a new port > type is added. Partner link types are used by BPEL processes. > In a BPEL process, a partner link represents the interaction between the > BPEL process and a partner service. Each partner link is associated with a > partner link type. > A partner link type characterizes the conversational relationship between > two services. The partner link type can have one or two roles.--> > <plnk:role name="YahooGeocodeWSDLPortTypeRole" > portType="tns:YahooGeocodeWSDLPortType"/> > </plnk:partnerLinkType> > </definitions> > > > ###################################################### > GeocodeResponse.XSD > ###################################################### > > <?xml version="1.0" encoding="utf-8" ?> > <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" > targetNamespace="urn:yahoo:maps" > xmlns="urn:yahoo:maps" > elementFormDefault="qualified"> > > <xs:element name="ResultSet"> > <xs:complexType> > <xs:sequence> > <xs:element name="Result" type="ResultType" minOccurs="0" maxOccurs="50" /> > </xs:sequence> > </xs:complexType> > </xs:element> > > <xs:complexType name="ResultType"> > <xs:sequence> > <xs:element name="Latitude" type="xs:decimal" /> > <xs:element name="Longitude" type="xs:decimal" /> > <xs:element name="Address" type="xs:string" /> > <xs:element name="City" type="xs:string" /> > <xs:element name="State" type="xs:string" /> > <xs:element name="Zip" type="xs:string" /> > <xs:element name="Country" type="xs:string" /> > </xs:sequence> > <xs:attribute name="precision" type="xs:string" /> > <xs:attribute name="warning" type="xs:string" use="optional"/> > </xs:complexType> > </xs:schema> >
