Hello again,
What are my options for running a potentially lengthy process using Dancer? I'm adapting old CGI.pm-based code, which uses one of two techniques:
1. the CGI creates a job that it sends to an externally-managed queue; users have a workspace area where they can check to see if their job has finished;
2. the CGI keeps the connection to the browser open while performing the process using a hack involving sending small chunks of data from time to time.
Another common technique (similar to 1 above) is to fork off a child process and have the browser periodically refresh the page, which triggers a check to see if the child process has finished (e.g. by checking for the presence of a results file) and the results can be loaded.
Do Dancer2's delayed / async / non-blocking capabilities offer any additional ways to deal with long-running processes, or maybe a more elegant way to do option 2?
Thank you for any information!
Amelia.