Lightweight HTTP application/server for static content

Posted by PartlyCloudy on Stack Overflow See other posts from Stack Overflow or by PartlyCloudy
Published on 2010-04-24T14:54:08Z Indexed on 2010/04/24 15:23 UTC
Read the original article Hit count: 193

Hi,

I am in need of a scalable and performant HTTP application/server that will be used for static file serving/uploading. So I only need support for GET and PUT operations.

However, there are a few extra features that I need:

  • Custom authentication: I need to check credentials against a database for each request. Thus I must be able to integrate propietary database interaction.
  • Support for signed access keys: The access to resources via PUT should be signed using a key like http://uri/?key=foo The key then contains information about the request like md5(user + path + secret) which allows me to block unwanted requests. The application/server should allow me to check for this.
  • Performance: I'd like to avoid piping content as much as possible. Otherwise the whole application could be implemented in Perl/etc. in a few lines as CGI.

Perlbal (in webserver mode) looks nice, however the single-threaded model does not fit with my database lookup and it does also not support query strings.

Lighttp/Nginx/… have some modules for these tasks, however it is not feasible putting everything together without ending up writing own extensions/modules.

So how would you solve this? Are there other leightweight webservers available for this? Should I implement an application inside of a webserver (i.e. CGI). How can I avoid/speed up piping content between the webserver and my application.

Thanks in advance!

© Stack Overflow or respective owner

Related posts about httpd

Related posts about webserver