nginx-0.6.6

Igor Sysoev is at rambler-co.ru
Tue Jul 31 00:58:07 MSD 2007


On Mon, Jul 30, 2007 at 12:08:35PM -0700, Ezra Zygmuntowicz wrote:

> On Jul 30, 2007, at 2:19 AM, Igor Sysoev wrote:
> 
> >Changes with nginx 0.6.6                                         30  
> >Jul 2007
> >    *) Feature: named locations.
> 
> Can you show a simple example?

The named location allows to do internal redirect without changing URI:

    location / {
        set             $memcached_key   "$uri$is_args$args";
        memcached_pass  host:11211;
        error_page      404 = @fallback;
    }

    location @fallback {
        proxy_pass      http://backend;
    }

> >    *) Feature: the $is_args variable.
> 
> What does this variable reference?

$is_args is equal to "?", if there are arguments and "", if not.

> >
> >    *) Bugfix: fair big weight upstream balancer.
> 
> Can you go into more details about this one? Is this a change in the  
> load balancing algorithm for upstream proxies?--

Yes, early if you define

upstream backend {
    server one weight=1000;
    server two weight=500;
}

then nginx did 1000 requests to "one", and then 500 requests to "two", then
all were again. Now nginx does requests as following:

one, two, one, one, two, one, one, two, one, one, two ...

> Thanks  for any clarification you can give. I'll add this to the wiki  
> once I understand how these features work.
> 
> 
> P.S  Is it still in your plans to add a connection rate limit feature  
> of the upstream proxy module?

Yes, I will do it.


-- 
Igor Sysoev
http://sysoev.ru/en/





More information about the nginx mailing list