Skip navigation
Currently Being Moderated

dataservice call fault error after session timeout does not get trapped in the fault handler

Jan 31, 2012 10:30 AM



My data service call after the session time out for about 30 mins, does not get trapped into the fault handler. It pops up a Flash player error on the AIR simulator. I have some code to handle for session timeout error in the faulthandler. My server returns an exception for session timeout. My server log shows that it returns the exception, but it does not return to fault handler, instead throws a fault error on the UI in form of popup.  I am using RTMP channel with below configuration.



<channel-definition id="mobility-rtmp"


      <endpoint url="rtmp://{}:@flex.rtmp.port@"











Please let me know how I can handle this.



  • Currently Being Moderated
    Jan 31, 2012 11:48 PM   in reply to betheflexcoder



    Can you post the code you are using to register the faultHandler? Just to confirm, you need to register the faultHandler at the service level like this:


    userService.addEventListener("fault", faultHandler);




    Ashish Vashisht

    Mark as:
  • Currently Being Moderated
    Feb 8, 2012 5:57 AM   in reply to betheflexcoder



    Sorry for the delayed response - I was out of office for the last week.


    Where you have instantiated your DataService (customdataservice variable), you should add an event handler for the fault event like this:


    customdataservice.addEventListener("fault", faultHandler);


    where faultHandler is the function you want called on a fault happening.


    For more information, see here: 3ff6d0ea77859461172e0811f00f7045b-7fb0Update.html data/DataService.html#eventSummary a1a89e415cd1e5d-d5245eb1221394e36f-8000Update.html




    Ashish Vashisht

    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points