Hi Dima, Thanks, for the suggestion, but unfortunately the wsdl files generated by glassfish for circular imports, but found no such issues. I've played around today more with my application to try and get more information to understand why the issue happens with using Cairngorm framework, but not embedded MXML Webservices.
I've noticed when using embedded MXML WebService in my test application when the application is loaded the WSDL files get loaded from the WebServer upon application load, but when I use Cairngorm 2.2 Beta (which has the loadWSDL() ) function the WSDL files do not seem to be loaded upon application load. It isn't until I make a call to a web service API that the WSDL files get loaded. I think this is perhaps related to my issue. I have the standard call to my Cairngorm webservice business:Services inside the MXML file containing my <mx:Application>, but I'm wondering why I do not see the web server get hit to grab the WSDL files. William --- In [email protected], "Dima Gutzeit" <[EMAIL PROTECTED]> wrote: > > Hi, > > I am working with JAX-WS 2.1 and the issue that Flex can not "congest" is curcular "xsd:import" where a imports b and b includes a. It gets into loop and dies :-) Maybe that is your problem. > > If that is the case you can optimize your namespaces not to include too much separate files. > > HIH. > > Regards, > Dima Gutzeit. > > BTW - The problem is supposed to be fixed in Flex SDK 2.5 Beta 2, which is not yet released. > > ----- Original Message ----- > From: klotzw > To: [email protected] > Sent: Monday, March 12, 2007 8:16 PM > Subject: [flexcoders] Flex WebServices and JAX-WS 2.0 WSDL.BadElement Error > > > Hello All, > > The company I work for decided it wished to create applications using > EJB 3.0 using Glassfish as the application server. They originally > wished me to use AJAX to create the UI, but I convinced them to allow > me to use Flex and Actionscript instead. I'm currently running into a > problem when accessing my JAX-WS webservice. I receive a > WSDL.BadElement Error when I tried to use the web service the first > time. The odd thing is the error is only happening when I use the > Cairngorm 2.1 and 2.2 Beta frameworks. If I use the MXML Webservices > I do not see the issue. I may still exist, but I do not recieve the > pop-up box within the web browser. > > The error seems to have to do with my WSDL file containing xsd:import, > but I have no control of this since JAX-WS 2.0 will only generate WSDL > files with xsd:import within the WSDL file. > > Has anyone else used JAX-WS 2.0 experienced this issue or know how to > resolve the issue. > > Thank you, > William > > Here's the error when I run my application. If I choose to continue I > am able to login and call web service API's without the error until > re-run the application. > > [WSDLError faultString="Element http://dpgdomain.com:logon not > resolvable" faultCode="WSDL.BadElement" faultDetail="null"] > at > mx.rpc.soap::WSDLParser/http://www.adobe.com/2006/flex/mx/internal::parseMessage() > at mx.rpc.soap::WSDLOperation/parseMessages() > at > mx.rpc.soap::Operation/http://www.adobe.com/2006/flex/mx/internal::invokePendingCall() > at > mx.rpc.soap::Operation/http://www.adobe.com/2006/flex/mx/internal::invokeAllPending() > at mx.rpc.soap::WebService/::unEnqueueCalls() > at > mx.rpc.soap::WebService/http://www.adobe.com/2006/flex/mx/internal::wsdlHandler() > at > flash.events::EventDispatcher/flash.events:EventDispatcher::dispatchEventFunction() > at flash.events::EventDispatcher/dispatchEvent() > at mx.rpc.soap::WSDLParser/dispatchEvent() > at mx.rpc.soap::WSDLParser/::parseCompleted() > at > mx.rpc.soap::WSDLParser/http://www.adobe.com/2006/flex/mx/internal::httpResultHandler() > at > flash.events::EventDispatcher/flash.events:EventDispatcher::dispatchEventFunction() > at flash.events::EventDispatcher/dispatchEvent() > at > mx.rpc::AbstractInvoker/http://www.adobe.com/2006/flex/mx/internal::dispatchRpcEvent() > at > mx.rpc::AbstractInvoker/http://www.adobe.com/2006/flex/mx/internal::resultHandler() > at mx.rpc::Responder/result() > at mx.rpc::AsyncRequest/acknowledge() > at ::DirectHTTPMessageResponder/completeHandler() > at > flash.events::EventDispatcher/flash.events:EventDispatcher::dispatchEventFunction() > at flash.events::EventDispatcher/dispatchEvent() > at flash.net::URLLoader/flash.net:URLLoader::onComplete() > > Here's my Services.mxml file declaring the WebService API's. > > <?xml version="1.0" encoding="utf-8"?> > <cairngorm:ServiceLocator > xmlns:mx="http://www.adobe.com/2006/mxml" > xmlns:cairngorm="http://www.adobe.com/2006/cairngorm"> > > <mx:WebService id="UserManagementWebService" > wsdl="http://localhost:8080/UserManagementWebService/UserManagement?wsdl" > useProxy="false" > showBusyCursor="true" > result="event.token.resultHandler( event );" > fault="event.token.faultHandler( event );"> > > <mx:operation name="getUserCurrentlyLoggedIn" > resultFormat="object" /> > > <mx:operation name="logout" resultFormat="object" /> > > <mx:operation name="logon" resultFormat="object"/> > </mx:WebService> > </cairngorm:ServiceLocator> > > If I create a test Application without Cairngorm the application works > without receiving the WSDL.BadElement Error. > > <?xml version="1.0"?> > <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"> > > <mx:WebService > id="logonService" > wsdl="http://localhost:8080/UserManagementWebServiceBeanService/UserManagementWebServiceBean?wsdl" > useProxy="false" > showBusyCursor="true" > fault="Alert.show(event.fault.faultString), 'Error'" > result="logonResult(event)" > > <mx:operation name="logon" resultFormat="object"/> > </mx:WebService> > > </mx:Application> >

