Fixed! With some help on the CXF side I was able to log the entire
SOAP message and see that I wasn't sending the right value. I was
using the wrong brackets [] in the mxml file instead of {}, so I was
sending 'fullOrderId.text' instead of the value of that field, and it
was expecting an int.

Actually, I could argue that the 'root cause' of this error was my
working from the PDF docs. My trial of Flex Builder 2 ran out earlier
this week so I had to download the docs, instead of using the help
files that Flex Builder opens up (I don't know what format those are
in, but they're easier to read). The code snippets in the PDF docs are
harder to read, very hard to distinguish between [] and {}.

--- In [email protected], "Brian" <[EMAIL PROTECTED]> wrote:
>
> I'm new to both Flex and the CXF/XFire API I'm using for simple web
> services. I've gotten a basic interface working with Flex, and a
> simple service working with CXF and deployed to Tomcat locally, so now
> I'm trying to connect the two. I was able to connect to the webservice
> with a simple client from the CXF tutorials so I know that's working. 
> 
> One of the errors in the tomcat log was an IllegalArgumentException. I
> searched the CXF user forums for similar issues, and found one poster
> who mentioned that Flex uses RPC and CXF defaults to document/literal,
> could that be a problem?
> 
> The error on the Flex side doesn't help much : 
> 
> [RPC Fault faultString="HTTP request error"
> faultCode="Server.Error.Request" faultDetail="Error: [IOErrorEvent
> type="ioError" bubbles=false cancelable=false eventPhase=2 text="Error
> #2032: Stream Error. URL:
> http://localhost:8080/OrderViewWeb/services/FullOrder";]. URL:
> http://localhost:8080/OrderViewWeb/services/FullOrder";]
>       at
>
mx.rpc::AbstractInvoker/http://www.adobe.com/2006/flex/mx/internal::faultHandler()
>       at mx.rpc::Responder/fault()
>       at mx.rpc::AsyncRequest/fault()
>       at ::DirectHTTPMessageResponder/errorHandler()
>       at
>
flash.events::EventDispatcher/flash.events:EventDispatcher::dispatchEventFunction()
>       at flash.events::EventDispatcher/dispatchEvent()
>       at flash.net::URLLoader/flash.net:URLLoader::redirectEvent()
> 
> Here's the wsdl, hope that's not too much : 
> 
> <?xml version="1.0" encoding="utf-8"?>
> <!-- Created with Liquid XML Studio 1.0.4.0
> (http://www.liquid-technologies.com) -->
> <wsdl:definitions xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/";
> xmlns:tns="http://services.project.company.com/";
> xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";
> xmlns:xsd="http://www.w3.org/2001/XMLSchema";
> name="FullOrderServiceImplService"
> targetNamespace="http://services.project.company.com/";>
>       <wsdl:types>
>               <xs:schema xmlns="http://services.project.company.com/";
> xmlns:xs="http://www.w3.org/2001/XMLSchema";
> attributeFormDefault="unqualified" elementFormDefault="unqualified"
> targetNamespace="http://services.project.company.com/";>
>                       <xs:complexType name="fullOrder">
>                               <xs:sequence>
>                                       <xs:element minOccurs="0" name="desc" 
> type="xs:string" />
>                                       <xs:element name="id" type="xs:int" />
>                               </xs:sequence>
>                       </xs:complexType>
>                       <xs:element name="getFullOrder" type="getFullOrder" />
>                       <xs:complexType name="getFullOrder">
>                               <xs:sequence>
>                                       <xs:element name="fullOrderId" 
> type="xs:int" />
>                               </xs:sequence>
>                       </xs:complexType>
>                       <xs:element name="getFullOrderResponse"
type="getFullOrderResponse" />
>                       <xs:complexType name="getFullOrderResponse">
>                               <xs:sequence>
>                                       <xs:element minOccurs="0" name="return" 
> type="fullOrder" />
>                               </xs:sequence>
>                       </xs:complexType>
>               </xs:schema>
>       </wsdl:types>
>       <wsdl:message name="getFullOrderResponse">
>               <wsdl:part element="tns:getFullOrderResponse" name="result">
>               </wsdl:part>
>       </wsdl:message>
>       <wsdl:message name="getFullOrder">
>               <wsdl:part element="tns:getFullOrder" name="parameters">
>               </wsdl:part>
>       </wsdl:message>
>       <wsdl:portType name="FullOrderService">
>               <wsdl:operation name="getFullOrder">
>                       <wsdl:input message="tns:getFullOrder" 
> name="getFullOrder">
>                       </wsdl:input>
>                       <wsdl:output message="tns:getFullOrderResponse"
> name="getFullOrderResponse">
>                       </wsdl:output>
>               </wsdl:operation>
>       </wsdl:portType>
>       <wsdl:binding name="FullOrderServiceImplServiceSoapBinding"
> type="tns:FullOrderService">
>               <soap:binding style="document"
> transport="http://schemas.xmlsoap.org/soap/http"; />
>               <wsdl:operation name="getFullOrder">
>                       <soap:operation soapAction="" style="document" />
>                       <wsdl:input name="getFullOrder">
>                               <soap:body use="literal" />
>                       </wsdl:input>
>                       <wsdl:output name="getFullOrderResponse">
>                               <soap:body use="literal" />
>                       </wsdl:output>
>               </wsdl:operation>
>       </wsdl:binding>
>       <wsdl:service name="FullOrderServiceImplService">
>               <wsdl:port binding="tns:FullOrderServiceImplServiceSoapBinding"
> name="FullOrderServiceImplPort">
>                       <soap:address
> location="http://localhost:8080/testWebApp/services/FullOrder"; />
>               </wsdl:port>
>       </wsdl:service>
> </wsdl:definitions>
>


Reply via email to