zoukankan      html  css  js  c++  java
  • sticky session 粘性会话

     New Elastic Load Balancing Feature: Sticky Sessions | AWS News Blog https://amazonaws-china.com/cn/blogs/aws/new-elastic-load-balancing-feature-sticky-sessions/

    New Elastic Load Balancing Feature: Sticky Sessions

    by Jeff Barr | on 07 APR 2010 | in Amazon EC2LaunchNews | Permalink |  Share

    Amazon EC2’s Elastic Load Balancing feature just became a bit more powerful. Up until now each load balancer had the freedom to forward each incoming HTTP or TCP request to any of the EC2 instances under its purview. This resulted in a reasonably even load on each instance, but it also meant that each instance would have to retrieve, manipulate, and store session data for each request without any possible benefit from locality of reference.

    Suppose two separate web browsers each request three separate web pages in turn. Each request can go to any of the EC2 instances behind the load balancer, like this:

    When a particular request reaches a given EC2 instance, the instance must retrieve information about the user from state data that must be stored globally. There’s no opportunity for the instance to cache any data since the odds that several requests from the same user / browser will go down as more instances are added to the load balancer.

    With the new sticky session feature, it is possible to instruct the load balancer to route repeated requests to the same EC2 instance whenever possible.

    In this case, the instances can cache user data locally for better performance. A series of requests from the user will be routed to the same EC2 instance if possible. If the instance has been terminated or has failed a recent health check, the load balancer will route the request to another instance. Of course, in a real world scenario, there would be more than two users, and the third EC2 instance wouldn’t be sitting idle.

    Full information on this new feature can be found in the Elastic Load Balancer documentation.

    Update: Shlomo Swidler wrote a really nice post on Elastic Load Balancing with Sticky Sessions. I’d encourage you to check it out to learn more about why sticky sessions can improve your application.

    — Jeff;

     
     
     
  • 相关阅读:
    SQL表连接查询inner join left join right join full join ...
    希尔伯特空间回顾(简直太好了)
    pytorch的matmul怎么广播
    pytorch怎么抽取中间的特征或者梯度
    winedt102安装
    数据挖掘 关联规则
    git 命令
    caffe: c++11支持
    匈牙利算法
    ubuntu两个conda安装和切换
  • 原文地址:https://www.cnblogs.com/rsapaper/p/7840703.html
Copyright © 2011-2022 走看看