Updating r->cache in ngx_http_upstream_process_cache_control()

2024-07-26 Thread Maksim Yevmenkin
Hello, I would like to understand the rationale for updating r->cache->valid_sec (and other fields in r->cache) in ngx_http_upstream_process_cache_control(). It appears that ngx_http_upstream_process_cache_control() can be called (via ngx_http_proxy_process_header()) in two scenarios: when

proxy_cache_lock for content revalidation

2024-05-30 Thread Maksim Yevmenkin
hello! it seems that the proxy_cache_lock directive operates only for cache misses (new content). while this behavior is documented, i am curious about the reasoning behind it. there are scenarios where proxy_cache_lock could be very beneficial for content revalidation. what are the community's

limiting number of HTTP request headers

2024-05-15 Thread Maksim Yevmenkin
Hello! Could the community share their thoughts on introducing a directive to cap the number of HTTP request headers? While we currently have the ability to limit client HTTP request buffer size, having more specific control over the number of headers could be advantageous. Thanks, max

[patch] reject http header without colon (:) in the header name

2024-05-07 Thread Maksim Yevmenkin
hello, it appears that nginx would happily accept http header without colon (:) in the header name. the patch below tries to address this. thanks max == --- a/ports/netflix/nginx/files/nginx/src/http/ngx_http_parse.c +++ b/ports/netflix/nginx/files/nginx/src/http/ngx_http_parse.c @@ -941,14

possible problem with ngx_palloc_small()

2020-08-31 Thread Maksim Yevmenkin
Hello, a colleague of mine sent me this == There is a problem in ngx_palloc_small() if it is called with arg 'align' set true when the small buffer is almost exhausted such that there are less bytes available in that buffer than the change in alignment consumes In that case, 'm' (the alignment

Re: Nginx tail module

2020-02-13 Thread Maksim Yevmenkin
On Wed, Feb 12, 2020, 11:07 PM Eran Kornblau wrote: > I don’t know what you’re trying to solve… but maybe you can just send a > range request relative to the end, > without any custom module. > For example, ‘Range: bytes=-1024’ will return the last 1k of the resource. > Thanks but this is not

Nginx tail module

2020-02-12 Thread Maksim Yevmenkin
Hello What would be the best way to write a Nginx module that would essentially tail a file? Thanks Max ___ nginx-devel mailing list nginx-devel@nginx.org http://mailman.nginx.org/mailman/listinfo/nginx-devel

Re: Fwd: 1.17.5 regression

2019-12-24 Thread Maksim Yevmenkin
hello! > Just to make sure it's known: the patch above was committed after > internal review/testing, and it is available as part of the 1.17.7 > release. would it be possible to publish 1.17.7 to https://github.com/nginx/nginx.git ? thanks! max ___

Re: Fwd: 1.17.5 regression

2019-12-19 Thread Maksim Yevmenkin
hello, [...] > > > > Thanks for the report, it indeed looks like a bug introduced > > > > in 9d2ad2fb4423. > > > > > > > > The problem is that c->read->handler is overwritted when switching > > > > to the next pipelined request, ngx_ssl_next_read_handler() is not > > > > called, and

streaming large nginx generated page

2015-11-09 Thread Maksim Yevmenkin
hello, suppose i need to export large amount of nginx generated data (static page). i have used content handler (or content phase handler) to create all the in-memory chain and fed it to ngx_http_output_filter(). however, i would very much like to avoid allocating large chunk of memory to keep