Poor performance when loading huge number of server section

Anb xofyarg+list at gmail.com
Sun Aug 11 16:11:59 UTC 2013


Thank you, Ruslan.

> How about mapping $server_name to upstream instead?
>
> map $server_name $upstream {
>     default ...;
>     [100k entries]
> }
>
> server {
>     ...
>     proxy_pass http://$upstream;
>     ...
> }

It works if I use simple upstream like url:80, but still very slow
when using upstream module. Since I need to sepcify a `upstream'
context for each server_name.

-- 
Anb
2013.8.12



More information about the nginx mailing list