Is there interest in a std.http?

Vladimir Panteleev vladimir at thecybershadow.net
Mon Nov 19 16:10:37 PST 2012


On Monday, 19 November 2012 at 20:38:56 UTC, Tyler Jameson Little 
wrote:
> * HTTP body is a stream

No Content-Size, no multiple requests per connection (unless you 
use chunked encoding?).

> * User settable size limits
>   * Size of request line (1024 bytes by default)
>   * Size of each header (1024 bytes by default)
>   * Total size of header block (4096 bytes by default)

I think this is pointless. Use an appender and the RFC limits. 
Unless you are serving VERY simple pages, the cost of a few 
allocations for handling the HTTP protocol's overhead will not be 
noticeable compared to the application's. (Slowloris is something 
to keep in mind, though.)

My HTTP library, which is used for this forum and several other 
"production" projects, is here: https://github.com/CyberShadow/ae
The main problem with getting it into Phobos is that it's tied to 
a lot of other related code, such as the asynchronous sockets 
module, the unmanaged memory wrapper type, etc.

Also, what about vibe.d?


More information about the Digitalmars-d mailing list