Hi Jason, See http://github.com/keplerproject/mk/blob/master/src/mk.lua. The serve_file method takes a WSAPI environment and a filename and returns a WSAPI response (a status, headers, iterator triple) that sends the file one block at a time, generating an ETag for it.
-- Fabio Mascarenhas 2010/6/1 Luís Eduardo Jason Santos <jasonsan...@gmail.com>: > Hi, > I am serving a very simple application using Xavante and at a certain point > I need to send a very large file to the client. > > I believe the filehandler.lua does what I need -- but its functions are not > accessible from the .lua file in the application. > I thought about copy-pasting the source from the handler into the > application, but then I found myself replicating the bootstrap of wsapi > response, and it felt really wrong. > Using the generic handler on wsapi (or even cgilua if I need), Is there a > way I am supposed to do this? > -- > Luís Eduardo Jason Santos > > _______________________________________________ > Kepler-Project mailing list > Kepler-Project@lists.luaforge.net > http://lists.luaforge.net/cgi-bin/mailman/listinfo/kepler-project > http://www.keplerproject.org/ > _______________________________________________ Kepler-Project mailing list Kepler-Project@lists.luaforge.net http://lists.luaforge.net/cgi-bin/mailman/listinfo/kepler-project http://www.keplerproject.org/