3 Replies Latest reply on Mar 30, 2010 10:57 AM by afrodom

    Flex to web service communication problem

    afrodom

      Hi, just as title state, I have problem during web service --> Flex communication. I am using WebService ActionScript class, to make a connection to it, but I got some odd behavior. When I try to access remote web service (particulary : http://109.74.206.146:8080/jax_ws/quarkservice?wsdl ) from my Flex Builder IDE, everything is fine. Even more, when I goes to my project folder and click ProjectName.swf file, without any server running on my pc, the file is executed, communication with web service is faultless performed, and response is retrieved. However, when I try to export as a build release, and to engage it to my localhost Tomcat, or if i try to copy ProjectName.swf to any another location on my had drive, from the project place, where is stored, I got :

       

      1. [RPC Fault faultString="Security error accessing url" faultCode="Channel.Security.Error" faultDetail="Unable to load WSDL. If currently online, please verify the URI and/or format of the WSDL (http://109.74.206.146:8080/jax_ws/quarkservice?wsdl)"]    

      2.   at mx.rpc.wsdl::WSDLLoader/faultHandler()[E:\dev\3.0.x\frameworks\projects\rpc\src\mx\rpc\ws dl\WSDLLoader.as:98]    

      3.   at flash.events::EventDispatcher/dispatchEventFunction()    

      4.  at flash.events::EventDispatcher/dispatchEvent()    

      5.    at mx.rpc::AbstractInvoker/http://www.adobe.com/2006/flex/mx/internal::dispatchRpcEvent()[E:\dev\3.0.x\frameworks\pro jects\rpc\src\mx\rpc\AbstractInvoker.as:168]    

      6.    at mx.rpc::AbstractInvoker/http://www.adobe.com/2006/flex/mx/internal::faultHandler()[E:\dev\3.0.x\frameworks\project s\rpc\src\mx\rpc\AbstractInvoker.as:220]    

      7.  at mx.rpc::Responder/fault()[E:\dev\3.0.x\frameworks\projects\rpc\src\mx\rpc\Responder.as:49 ]    

      8.     at mx.rpc::AsyncRequest/fault()[E:\dev\3.0.x\frameworks\projects\rpc\src\mx\rpc\AsyncRequest .as:103]    

      9.    at DirectHTTPMessageResponder/securityErrorHandler()[E:\dev\3.0.x\frameworks\projects\rpc\sr c\mx\messaging\channels\DirectHTTPChannel.as:368]   

      10.   at flash.events::EventDispatcher/dispatchEventFunction()   

      11.  at flash.events::EventDispatcher/dispatchEvent()   

      12.   at flash.net::URLLoader/redirectEvent()

       

      [RPC Fault faultString="Security error accessing url" faultCode="Channel.Security.Error" faultDetail="Unable to load WSDL.

      <br /> If currently online, please verify the URI and/or format of the WSDL (http://109.74.206.146:8080/jax_ws/quarkservice?wsdl)"] at

       

      mx.rpc.wsdl::WSDLLoader/faultHandler()[E:\dev\3.0.x\frameworks\projects\rpc\src\mx\rpc\wsd l\WSDLLoader.as:98]

      at flash.events::EventDispatcher/dispatchEventFunction()

      at flash.events::EventDispatcher/dispatchEvent() at mx.rpc::AbstractInvoker/http://www.adobe.com/2006/flex/mx/internal::dispatchRpcEvent()[E:\dev\3.0.x\frameworks\pro jects\rpc\src\mx\rpc\AbstractInvoker.as:168]

      at mx.rpc::AbstractInvoker/http://www.adobe.com/2006/flex/mx/internal::faultHandler()[E:\dev\3.0.x\frameworks\project s\rpc\src\mx\rpc \AbstractInvoker.as:220]

      at mx.rpc::Responder/fault()[E:\dev\3.0.x\frameworks\projects\rpc\src\mx\rpc\Responder.as:49 ]

      at mx.rpc::AsyncRequest/fault()[E:\dev\3.0.x\frameworks\projects\rpc\src\mx\rpc\AsyncRequest .as:103]

      at DirectHTTPMessageResponder/securityErrorHandler()[E:\dev\3.0.x\frameworks\projects\rpc\sr c\mx\messaging\channels\DirectHTTPChannel.as:368]

      at flash.events::EventDispatcher/dispatchEventFunction() at flash.events::EventDispatcher/dispatchEvent()

      at flash.net::URLLoader/redirectEvent()

       

       

      So, the same file engaged from the FlexBuilder or directly invoked from the project's folder, where it reside, works perfectly. When I try to invoke it from ANY OTHER location, including deployment on my local Tomcat (or even simply from my desktop), I got the exception above. So, does anyone know what is the problem? Thanks