[dancer-users] [Dancer-users] recommended way to return large dynamic data?

sawyer x xsawyerx at gmail.com
Wed Oct 31 15:04:12 GMT 2012


Output buffering is handled by the Perl process, so you can use the $|
variable to control that.

On Wed, Oct 31, 2012 at 4:50 PM, Gordon, Assaf <gordon at cshl.edu> wrote:

> Beautiful!
>
> Now there's just one more thing I'm trying to do: have an automagic way to
> capture STDOUT and send it asynchronously back to the client (using
> async_send() ).
> This will allow using dancer to send output just like old cgi programs
> (and also execute external programs to generate big output).
>
> Something like Tie::STDOUT - but it only captures STDOUT inside perl code
> (no external programs)
> Or Capture::Tiny - but it seems to do buffering.
>
> So I'm not a sure how to implement it yet.
>
> -Gordon
>
>
>
>
>
> On Oct 31, 2012, at 10:34 AM, "sawyer x" <xsawyerx at gmail.com<mailto:
> xsawyerx at gmail.com>> wrote:
>
> You might be interested in this usage case:
> https://gist.github.com/3987355
>
> It allows you to run async code in a fork, wait for it in a condition
> variable and send it asynchronously to the user.
> It's based on Gordon's (ab)use of my insane additions to the send_file()
> function in Dancer.
>
> s.
> _______________________________________________
> dancer-users mailing list
> dancer-users at dancer.pm<mailto:dancer-users at dancer.pm>
> http://lists.preshweb.co.uk/mailman/listinfo/dancer-users
> _______________________________________________
> dancer-users mailing list
> dancer-users at dancer.pm
> http://lists.preshweb.co.uk/mailman/listinfo/dancer-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.preshweb.co.uk/pipermail/dancer-users/attachments/20121031/92bb6558/attachment.htm>


More information about the dancer-users mailing list