[Bug 8437] Large database backups and large exports from export.pl fail under plack
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8437 --- Comment #29 from David Cook <dcook@prosentient.com.au> --- (In reply to Kyle M Hall from comment #24)
Avoiding plack will 'fix' the script, but most likely cause everyone to stop looking for an actual solution. That's my worry. That being said, it's probably better to get it working in the near-term.
I'm looking at export.pl and thinking how export.pl's job should be to authenticate the user, process user input about what to download, and then direct the user somewhere else better suited to serving files... This is kind of interesting although perhaps not relevant in our hybrid CGI/PSGI way of doing things, and it's old so doesn't take into account that X-Sendfile seems deprecated: http://www.catalystframework.org/calendar/2014/5 But it does make the point that trying to serve a large file from Perl is going to be slow. It might be worth looking at frameworks using Plack to see how they do it. For example send_file and _send_file in Dancer: https://metacpan.org/release/Dancer/source/lib/Dancer.pm. Or we could look at https://metacpan.org/release/Plack/source/lib/Plack/App/File.pm, although that looks like it uses PSGI magic to send the file too, which would be tricky in our hybrid environment. -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org