From 52629e7a82dddc9c1aa8ae13b911571dd9b927ca Mon Sep 17 00:00:00 2001 From: Harvey Tuch Date: Fri, 23 Mar 2018 17:08:12 -0400 Subject: [PATCH 1/4] lb: release notes and unhide fields for locality based balancing. Signed-off-by: Harvey Tuch --- docs/root/intro/version_history.rst | 2 ++ envoy/api/v2/cds.proto | 2 -- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/root/intro/version_history.rst b/docs/root/intro/version_history.rst index 4c86ec36e..45b4e29d2 100644 --- a/docs/root/intro/version_history.rst +++ b/docs/root/intro/version_history.rst @@ -7,6 +7,8 @@ Version history ` support. The round robin scheduler now respects endpoint weights and also has improved fidelity across picks. +* :ref:`Locality weighted load balancing ` + is now supported. 1.6.0 ===== diff --git a/envoy/api/v2/cds.proto b/envoy/api/v2/cds.proto index 38e8f2aff..7d5c20160 100644 --- a/envoy/api/v2/cds.proto +++ b/envoy/api/v2/cds.proto @@ -394,13 +394,11 @@ message Cluster { } // Configuration for :ref:`locality weighted load balancing // ` - // [#not-implemented-hide:] message LocalityWeightedLbConfig { } oneof locality_config_specifier { // [#not-implemented-hide:] ZoneAwareLbConfig zone_aware_lb_config = 2; - // [#not-implemented-hide:] LocalityWeightedLbConfig locality_weighted_lb_config = 3; } } From d522bd5dcb8e1cb3754fe23daf2fbea694777ac8 Mon Sep 17 00:00:00 2001 From: Harvey Tuch Date: Fri, 23 Mar 2018 17:21:28 -0400 Subject: [PATCH 2/4] wip Signed-off-by: Harvey Tuch --- docs/root/intro/arch_overview/load_balancing.rst | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/docs/root/intro/arch_overview/load_balancing.rst b/docs/root/intro/arch_overview/load_balancing.rst index 4984b6de6..32c5a7d3f 100644 --- a/docs/root/intro/arch_overview/load_balancing.rst +++ b/docs/root/intro/arch_overview/load_balancing.rst @@ -309,6 +309,13 @@ picked. The load balancer follows these steps: 2. Pick locality (as described in this section) within priority level from (1). 3. Pick endpoint using cluster specified load balancer within locality from (2). +Locality weighted load balancing is configured by setting +:ref:`locality_weighted_lb_config +` in the +cluster configuration and providing weights in :ref:`LocalityLbEndpoints +` via :ref:`load_balancing_weight +`. + .. _arch_overview_load_balancer_subsets: Load Balancer Subsets From 68d6b5e6d3e593eaa93643866c75090df3bb65af Mon Sep 17 00:00:00 2001 From: Harvey Tuch Date: Thu, 29 Mar 2018 10:21:34 -0400 Subject: [PATCH 3/4] Added docs to point out this is not compatible with subsets. Signed-off-by: Harvey Tuch --- docs/root/intro/arch_overview/load_balancing.rst | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docs/root/intro/arch_overview/load_balancing.rst b/docs/root/intro/arch_overview/load_balancing.rst index 32c5a7d3f..c9def1559 100644 --- a/docs/root/intro/arch_overview/load_balancing.rst +++ b/docs/root/intro/arch_overview/load_balancing.rst @@ -316,6 +316,10 @@ cluster configuration and providing weights in :ref:`LocalityLbEndpoints ` via :ref:`load_balancing_weight `. +This feature is not compatible with :ref:`load balancer subsetting +`, since it is not straightforward to +reconcile locality level weighting with sensible weights for individual subsets. + .. _arch_overview_load_balancer_subsets: Load Balancer Subsets From b6b17eed9a6c1aa942a48dd9ce92aa1d33add227 Mon Sep 17 00:00:00 2001 From: Harvey Tuch Date: Fri, 6 Apr 2018 17:03:56 -0400 Subject: [PATCH 4/4] Note that ring hash doesn't support locality LB. Signed-off-by: Harvey Tuch --- docs/root/intro/arch_overview/load_balancing.rst | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/docs/root/intro/arch_overview/load_balancing.rst b/docs/root/intro/arch_overview/load_balancing.rst index c9def1559..d5bb5fcd2 100644 --- a/docs/root/intro/arch_overview/load_balancing.rst +++ b/docs/root/intro/arch_overview/load_balancing.rst @@ -59,6 +59,11 @@ currently support weighting. When priority based load balancing is in use, the priority level is also chosen by hash, so the endpoint selected will still be consistent when the set of backends is stable. +.. note:: + + The ring hash load balancer does not support :ref:`locality weighted load + balancing `. + .. _arch_overview_load_balancing_types_maglev: Maglev