5 Replies Latest reply on Mar 16, 2011 10:49 AM by rtalton

    WSDL Call generates thousands of requests

    80RedEagle80

      Hello everyone,

       

      I am trying to access a Web Service.

       

      I'm able to load that Web Service in .NET or even SOAP UI, and the response is returned quicly and correctly.

       

      That web service references several XSD files. Those XSD files follow this kind of "order":

       

      <call.xsd>   
        
      <input.xsd>
        
      </input.xsd>
        
      <output.xsd>
           
      <class1.xsd>

               <struct1.xsd />

               <struct1.xsd />
               ...

               <struct1.xsd />
           
      </class1.xsd>
           
      <class2.xsd>

               <struct2.xsd />      </class2.xsd>
           
      <class3.xsd>

               <struct2.xsd />
               ...

               <struct2.xsd />

               <struct3.xsd />

               <struct3.xsd />
               ...
            </class3.xsd>
        
      </output.xsd>
      </call.xsd>

               <struct3.xsd />

      On the Network Monitor there are thousands of requests to the struct XSD's and there are no result or fault events....

       

      I've even noticed that if I only try to load the Web Service I get the same behavior

       

      Here's how I'me loading it:

       

      ... creationComplete="init()"

       

      <fx:Script>

       

      private function init():void {        
         service.loadWSDL();  
      }

      protected function loadHandler(event:LoadEvent):void {
      //DEBUG HERE
      }

       

      <fx:/Script>

       

       

      <s:WebService id="service" wsdl="http://...WebService.wsdl" load="loadHandler(event)" />

       

      Any ideas why this happens?

       

      Isn't there a way to limit the requests to the same address.

       

      I've tried severall things since the struct.xsd schema has one element with the "maxOccurs="unbounded" but the same thing everytime.

       

      Please help.

       

      Thanks

        • 1. Re: WSDL Call generates thousands of requests
          curtis33321 Level 1

          I think you are doing this the hard way unless you are trying to dynamically introspect the service because you don't know what methods will be available.  The recommended (and the way I use) way to create WSDL WebService connections would be to go to the Data menu and choose Connect to  WebService...

           

          here you can give yoru service a name and place the webservice url (including the WSDL ending) and it will import all the methods for you.  Then in your component you want to utilize the webservice in, simply create an instance of th eservice name in the Declarations section and you have intellisense type of support for the different methods available on the webservice.    

          • 2. Re: WSDL Call generates thousands of requests
            80RedEagle80 Level 1

            Hey Curtis,

             

            Thanks for the hint but I already tried it that way and still get the same problem.

             

            This happens, even if I don't create a load event for the Web Service component and just create a result event.

             

            The thing that I don't understand is why it calls the same XSD thousand of times...

             

            Thanks anyway

            • 3. Re: WSDL Call generates thousands of requests
              80RedEagle80 Level 1

              Giving some more detail to my response I have this XSD structure on the Axis2 (Java) Web Service:

               

              CALL

                 INPUT

                 OUTPUT

                    CLASS1

                       STRUCT1 -> can have one or many

                    CLASS2

                       STRUCT2 -> can have one or many

                    CLASS3

                       STRUCT3 -> can have one or many

               

              Using the Connect to Data Service I get a structure of AS classes that look like this:

               

              CALL

                 INPUT

                 OUTPUT

                    STRUCT1

                    STRUCT2    

                    STRUCT3

               

              Using the generated component that Curtis mentioned, I still get thousands of requests to the STRUCTs XSD's

               

              Hope it helps...

              • 4. Re: WSDL Call generates thousands of requests
                curtis33321 Level 1

                My experience has only been with .NET webservices, sorry.

                • 5. Re: WSDL Call generates thousands of requests
                  rtalton Level 4

                  If you have specified the WSDL in the MXML tag, it is loaded automatically, so you do NOT have to call the loadWSDL () method.

                   

                  Also (and like curtis33321, I am using .NET), you may need to specify the WSDL URI differently.
                  .NET uses a "gateway" file, so you do it like this: wsdl="http://...MyWebService.asmx?wsdl".
                  ...note the ?wsdl; this should also be used for your java service URI.

                   

                  In Java, I'm not certain but it could be something like: "http://...MyJavaWebService/MyJavaServiceClass?wsdl"

                  Not sure how your web service file was created or how it was implemented on the server.