serving multiple files as a zip

alex alex at state51.co.uk
Mon May 8 14:45:10 UTC 2006


Would be happy to make something.  I can't see any useful plugin hooks
for this in the code though.  Any hints for how I can go about this?

I suppose the plugin should be able to take control if certain headers
are present, streaming the zip header and data for each URL in turn
followed by the zip file index.

On Fri, 2006-05-05 at 16:05 +0000, Brad Fitzpatrick wrote:
> We've wanted to to this for our photo hosting site for ages but have never
> gotten around to it.
> 
> If you write the Perlbal plugin, I'd love it!
> 
> 
> On Fri, 5 May 2006, alex wrote:
> 
> >
> > It's nice to allow web users to download several files in one go.  For
> > example choose 5 tracks they like from an album and download a zip.
> >
> > I was wondering if this could be sensible
> >
> > 1/ User clicks on a link
> > 2/ perlbal gets the request, proxies it
> > 3/ apache gets the request, maps the link to five files, returns a
> > reproxy header giving the relevant file locations
> > 4/ perlbal serves the files back to the user, combined into an
> > uncompressed application/zip file
> >
> > Step four wouldn't require any extra memory or disk usage, latency or
> > cpu.  Zip files can be streamed as they're constructed.  It's possible
> > to predict the size of zip files and its parts in advance by doing a
> > HEAD request for each part and adding on header size, so byte range
> > support can work.
> >
> > So, a good idea?  I can share some potentially useful code if so, I've
> > got this kind of zip file streaming working in Perl already with a
> > subclass of Archive::Zip::Member.
> >
> > alex
> >
> >
> >



More information about the perlbal mailing list