Welcome! Log In Create A New Profile

Advanced

questions about proxy buffers

Xavier Noria
June 10, 2011 07:52PM
Hello,

I have read the documentation of the HTTP Proxy Module regarding
buffers and would like to understand which is the exact (basic)
workflow regarding buffers only. Let me ask about some scenarios,
assuming everything fits in memory and ignoring caching workflows etc.

Let's suppose proxy_buffer_size is 4k and proxy_buffers is 8 4k.

Say the proxied server sends a response of 2k. Then I guess the entire
response is buffered, as quickly as possible, and when the proxied
server is done, then nginx starts sending the buffer to the client. Is
that right?

The description of proxy_buffer_size says "This directive set the
buffer size, into which will be read the first part of the response,
obtained from the proxied server." What is the *first* part of the
response? Does it mean the chunk that fits in the first buffer? In
this case exactly 4k? If that's correct, what does the module do with
the "subsequent" parts? does proxy_buffer_size have anything to do
with them? Or are those for the remaining 7 buffers, 4k each?

Let's say now the proxied server sends a response consisting of 16k.
Does the module fill 4 buffers, as quickly as possible, and when
everything is done it sends the 16k to the client? Or does it start
sending the first buffer while filling the second one?

Here "nginx does not attempt to read the entire answer from the
proxied server, the maximum size of data which nginx can accept from
the server is set by directive proxy_buffer_size." should
proxy_buffer_size be proxy_buffers, or rather a combination of the
two?

What happens if the proxied server sends a response greater than the
total buffer sizes, say 50k? Does nginx frees buffers sending data,
and then buffers another chunk from the proxied server, iterate until
done?

What's proxy_busy_buffers_size?

Thanks!!!

_______________________________________________
nginx mailing list
nginx@nginx.org
http://nginx.org/mailman/listinfo/nginx
Subject Author Posted

questions about proxy buffers

Xavier Noria June 10, 2011 07:52PM

Re: questions about proxy buffers

Alexandr Gomoliako June 10, 2011 08:36PM

Re: questions about proxy buffers

Maxim Dounin June 10, 2011 10:10PM

Re: questions about proxy buffers

Xavier Noria June 12, 2011 02:30PM

Re: questions about proxy buffers

Maxim Dounin June 13, 2011 05:58PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 235
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready