[Dancer-users] ajax progress update

Mr. Puneet Kishor punk.kish at gmail.com
Fri Jul 22 13:54:36 CEST 2011


On certain client action, my app is firing several, concurrent, ajax requests fielded by difference Dancer servers. Some requests are completed quickly, others take a long time. Since they are asynchronous, there is little feedback for the user who might start fidgeting around thereby firing more ajax requests inadvertently. Two things --

One, how can I ignore or reject the extra requests that are a result of fidgety behavior? I realize this is a not a Dancer-specific question per se, but, one, you guys are likely to have some helpful suggestions, and two, I want to have a fall-back on the server side also -- if Dancer is busy with a request from a client, is there a way to ignore further requests from the same client until at least the first one is complete?

Two, this is more Dancer-specific, I guess -- once Dancer starts a process, how can I send periodic updates on that process back to the browser to power an ajax-y progress bar? My intent is to show a little floating div with a progress bar for each of the processes that were fired by the client.

Puneet.


More information about the Dancer-users mailing list