1 Reply Latest reply on Apr 29, 2009 6:52 PM by Gregory Lafrance

    HttpService + Asynchronous + Single thread

    arisco97

      I have a internal company Flex app similar to Jmeter. It generates HTTP requests and outputs based on asserts. The app uses Puremvc and leverages notifications to bring event-based asynchronous model. On a full-blown scan, I have two challenges:

      1. To throttle requests so that the view is quick to appear (initially). A full blown scan generates 1040 requests, and the view doesn't appear for a few secs till all the requests are queued. Is there a way, I can force the view to come quickly before I complete the pushing of requests.  I have implemented a throttle approach, but the results are not any better than no throttling.

      2. I am forced to set httpservice.requestTimeout to 300 secs, as what I have found is that the thread eventually forces the timeout as due the single threading model, Flex hasn't been able to send the request through before a normal timeout of 15 secs is completed.

      3. Is there a way to open more persistent connections to leverage, so that the performance of such bursts are improved?

       

      Don't expect a reply, but any thoughts are welcome.....

        • 1. Re: HttpService + Asynchronous + Single thread
          Gregory Lafrance Level 6

          Here is an ActionScript library that supposedly allows you to come closer to multi-threading:

           

          http://code.google.com/p/async-threading/downloads/list

           

          If you just want the UI to appear, have or generate minimal sample data, to be replaced as the data comes in. That way the UI can come up with reasonable minimum data for the UI.

           

          Can the requests either be chunked into small pieces to facilitate quicker completion of requests, or else larger chunks to reduce the overall number of requests.

           

          Can you compress the data and decompress after receipt to reduce the transfer load?

           

          With your volume of requests it boils down to experimentation and consideration and what gives the best performance. I've never dealt with such issues, but thought I would share my ideas.

          1 person found this helpful