locked
Do we have any lead time from application which can hold application even if web service takes 5 minutes and app wait for it.

    Question

  • i am developing a windows store app using html5 css3 and javascript.

    in which i am using async web service calls. and in which we have 1-2 web services which takes more than 3 minutes.

    will application be able to hault till 3 minutes or any specific time till what application can hault.

    Tuesday, April 8, 2014 2:22 PM

All replies

  • It depends on what you mean by "hault". The app cannot bay for any noticeable tint, but you can show a waiting screen and disable any input.

    It would be friendlier to load the darts in the backend and let the user work with what is available while waiting if that makes any sense for the scenario.

    Tuesday, April 8, 2014 2:46 PM
    Owner
  • I'd re-think the app/web service interaction - it will be near impossible to guarantee a 3 minute "cannot disconnect"  period, especially with impatient users, cellular or WiFi radio reception and the possibility of other phone app-interruptions such as calls or accidental app switching.

    Instead, and as Rob suggests, try to fire off a "create job" request which the server processes.  Return some sort of job ID, and then the phone can happily make short little requests to the service for status or job results (or you can send a push notification uri in the "create job phase" and then fire a toast notification back to the phone when the job is done...)


    Darin R.

    Tuesday, April 8, 2014 7:05 PM
  • First of all Thank you very much Dari and Rob for your response.

    Rob: yes there will be a loading image while web service call is going on.

    Darin: when i say can not disconnect. if user doesnt disconnect on its own will our application will crash or not.

    Friday, April 11, 2014 6:01 PM
  • I'm not sure I follow your last statement.

    Think of the client calling the server like this:

    StartJob

    ... the server gives a job ID

    CheckJob ?Job=jobid

    CheckJob ?Job=jobid

    CheckJob ?Job=jobid

    ... 3 minutes later, eventually CheckJob on the server returns Yes, Job done.

    GetJobResults  ?Job=jobid


    Darin R.

    Friday, April 11, 2014 9:50 PM