Re: [Boa-devel] Dynamic Content
Brought to you by:
jnelson
From: <la...@do...> - 2003-02-04 04:04:42
|
Allan - > Has anyone thought about a faster alternative to CGI for serving dynamic > content with boa? Yes. Oh, you want an answer, too? ;-) > I am aware of the general approach of embedding an > interpreter in the web server, and there is of course fastcgi which is > scary in a different way. Neither seem compatible to small is good > philosophy. What would be? IMHO, fastcgi merely postpones the problem. Instead of embedding an interpreter, you could instead simply "plug-in" the application program, with a dynamic loader. That latter possibility places complete control in the hands of the application to never stall. It might be better to keep control, in the form of a properly designed and debugged interpreter. Any candidate interpreter has to be able to perform direct (in-memory, not network transaction based) database queries, using something like gdbm. The output is obviously HTML. It's OK to have "source code" compiled down to "byte code" that the server "interprets". The interpreter has to keep "per-thread" state explicitly (not just in the Boa program counter), so when a buffer fills, Boa's main file-descriptor loop can take over. Like I said, I have thought about this off-and-on for years, and never put anything in. I have studied the available code base, e.g., php and other scripting languages, and never found anything that was programming-model compatible with Boa. Some things that come close, like php, are license-incompatible. I'm not scared to code something up, if I think it makes sense, could do real-world work, and people would use it. - Larry |