3 Replies Latest reply on Dec 2, 2008 3:27 PM by rtalton

    AIR doesn't terminate with pending web service requests

    Netom80
      I'm using webservices via the wsdl import tool in the Flex Builder 3.0.2. So far, I'm able to make requests to the webserver and get data from it successfully. The app is basically polling data from the server and when the server gets data, it sends it to the AIR client. As a Flex app inside the browser, the browser terminates fine. However, when I move the app to AIR, adl.exe never terminates, even when I call nativeApplication.exit(0), explicitly. (I noticed this issue when my machine started to thrash with 10 adl.exe running simultaneously.)

      Am I not calling exit correctly? Or is this a bug in AIR?
        • 1. Re: AIR doesn't terminate with pending web service requests
          Level 7

          "Netom80" <webforumsuser@macromedia.com> wrote in message
          news:ggf82l$1fi$1@forums.macromedia.com...
          > I'm using webservices via the wsdl import tool in the Flex Builder 3.0.2.
          > So
          > far, I'm able to make requests to the webserver and get data from it
          > successfully. The app is basically polling data from the server and when
          > the
          > server gets data, it sends it to the AIR client. As a Flex app inside the
          > browser, the browser terminates fine. However, when I move the app to
          > AIR,
          > adl.exe never terminates, even when I call nativeApplication.exit(0),
          > explicitly. (I noticed this issue when my machine started to thrash with
          > 10
          > adl.exe running simultaneously.)
          >
          > Am I not calling exit correctly? Or is this a bug in AIR?
          >

          Whenever I've seen this, I had a window that was not visible and for some
          reason (like an error before when I made it visible), it never became
          visible and so was not possible to terminate.

          HTH;

          Amy


          • 2. Re: AIR doesn't terminate with pending web service requests
            Netom80 Level 1
            Hmm... yeah, I think this may be a bug. Fortunately, I found a alternative solution, although it won't work if the server crashes. For our webservices, from the server side, I was able to tell it to end the session, and it sends empty responses to pending requests, thus allowing the Flex app to quit.

            • 3. Re: AIR doesn't terminate with pending web service requests
              rtalton Level 4
              What happens when you run the AIR app without using ADL? Could it be an issue with the debug launcher that wouldn't affect the compiled app?