keepalive:设置长连接数量
    proxy_http_version :设置长连接http版本为1.1
    proxy_set_header :清除connection header 信息

    upstream tomcats { 
                # server 192.168.1.173:8080 max_fails=2 fail_timeout=1s;
          server 192.168.1.190:8080;
          # server 192.168.1.174:8080 weight=1;
          # server 192.168.1.175:8080 weight=1; 
          keepalive 32;  #长连接数量 不是越大越好,一般设置cpu数量*2
        }
    
    
      server {
              listen 80; server_name www.tomcats.com; 
          location / { 
                  proxy_pass http://tomcats; 
              proxy_http_version 1.1; 
              proxy_set_header Connection ""; 
              } 
          }  
    
        可以用压测工具测试并发数量,对比下没有设置该参数时的并发数