[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Serving files with guile web server

From: Neil Jerram
Subject: Re: Serving files with guile web server
Date: Sat, 19 Mar 2011 02:20:47 +0000
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux)

address@hidden writes:

> I gave a second read to the manual and found:
> "The handler should return two values: the response, as a <response>
> record from (web response), and the response body as a string, bytevector,
> or #f if not present."
> If this is correct then I guess I should check the file type first and
> then read the file to either create a string or a bytevector from it.
> Any recommendation will be highly appreciated.

Well, I suppose I'd recommend considering not using the Guile server to
serve static files.  Using Guile makes more sense when you want to
generate dynamic content, because then you're really using the
capabilities of the language.

In my web server experiments so far I've used Apache, modlisp and Guile
together, and this combination seems to work well.  Then Apache can
handle all the static content (I guess using the efficient sendfile)
without bothering modlisp or Guile, but dynamic stuff can be routed via
modlisp to Guile.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]