Implementing HTTP/1.1 request chunking

agentzh agentzh at
Fri Jan 15 13:04:44 MSK 2010

On Fri, Jan 15, 2010 at 3:19 PM, Ian Greenhoe <ian.greenhoe at> wrote:
> So, my question is this --
> What, as a developer, would I need to do so that I could create a patch for
> this that would be accepted as part of the Nginx distribution?

I started writing the ngx_chunkin module just because it's
particularly hard (for me) to create a patch (of this size) that can
be accepted by Igor Sysoev. Patching the core would be much much
easier than doing chunked reading from outside :)

> I know that some of the items on this list so far are:
> 1) That the patch works.

ngx_chunkin works :) AFAIK, some people have already put it into production :)

> 2) Error checking -- check the size of the chunks & that the series of
> chunks are terminated properly.

ngx_chunkin honors the http core module's max_client_body_size
directive settings, as well as the client_body_buffer_size and
client_body_timeout settings.

> 3) Don't use Ragel. :)  Or, for that matter, any tool not already in use by
> the Nginx build process.

Okay, ngx_chunkin uses Ragel just to eliminate a lot of boring code
for truly streaming parsing. Fortunately we can generate C source
before we make a release such that the end user don't need to know
anything about Ragel :)

I'm not meant to discourage your efforts. If your patch gets accepted
by the core, I'd happily mark ngx_chunkin as obsolete and just
encourage people to use it if they have to stick with an earlier nginx
version for some reasons.


More information about the nginx mailing list