Skip to content

Commit

Permalink
WRR: xDS LB policy support (grpc#32067)
Browse files Browse the repository at this point in the history
* WRR: port StaticStrideScheduler to OSS

* WIP

* Automated change: Fix sanity tests

* fix build

* remove unused aliases

* fix another type mismatch

* remove unnecessary include

* move benchmarks to their own file, and don't run it on windows

* Automated change: Fix sanity tests

* add OOB reporting

* generate_projects

* clang-format

* add config parser test

* clang-tidy and minimize lock contention

* add config defaults

* add oob_reporting_period config field and add basic test

* Automated change: Fix sanity tests

* fix test

* change test to use basic RR

* WIP: started exposing peer address to LB policy API

* first WRR test passing!

* small cleanup

* port RR fix to WRR

* test helper refactoring

* more test helper refactoring

* WIP: trying to fix test to have the right weights

* more WIP -- need to make pickers DualRefCounted

* fix timer ref handling and get tests working

* clang-format

* iwyu and generate_projects

* fix build

* add test for OOB reporting

* keep only READY subchannels in the picker

* add file missed in a previous commit

* fix sanity

* iwyu

* add weight expiration period

* add tests for weight update period and OOB reporting period

* Automated change: Fix sanity tests

* lower bound for timer interval

* consistently apply grpc_test_slowdown_factor()

* cache time in test

* add blackout_period tests

* avoid some unnecessary copies

* clang-format

* add field to config test

* simplify orca watcher tracking

* attempt to fix build

* iwyu

* generate_projects

* update xds proto dependency

* add xDS LB policy entry to registry

* add "_experimental" suffix to policy name

* update LB policy name and remove debug log

* add env var protection

* generate_projects

* gen_upb_api

* WRR: update tests to cover qps plumbing

* WIP

* Automated change: Fix sanity tests

* more WIP

* basic WRR e2e test working

* add OOB test

* add xDS WRR e2e test

* clang-format

* fix sanity

* ignore duplicate addresses

* Automated change: Fix sanity tests

* add new tracer to doc/environment_variables.md

* retain scheduler state across pickers

* Automated change: Fix sanity tests

* use separate mutexes for scheduler and timer

* sort addresses to avoid index churn

* remove fetch_sub for wrap around in RR case

Co-authored-by: markdroth <[email protected]>
  • Loading branch information
markdroth and markdroth authored Jan 23, 2023
1 parent cf424f4 commit 8a02496
Show file tree
Hide file tree
Showing 115 changed files with 6,526 additions and 3,016 deletions.
5 changes: 5 additions & 0 deletions BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -3797,6 +3797,11 @@ grpc_upb_proto_library(
deps = ["@envoy_api//envoy/type/http/v3:pkg"],
)

grpc_upb_proto_library(
name = "envoy_extensions_load_balancing_policies_client_side_weighted_round_robin_upb",
deps = ["@envoy_api//envoy/extensions/load_balancing_policies/client_side_weighted_round_robin/v3:pkg"],
)

grpc_upb_proto_library(
name = "envoy_extensions_load_balancing_policies_ring_hash_upb",
deps = ["@envoy_api//envoy/extensions/load_balancing_policies/ring_hash/v3:pkg"],
Expand Down
216 changes: 210 additions & 6 deletions CMakeLists.txt

Large diffs are not rendered by default.

12 changes: 12 additions & 0 deletions Makefile

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions bazel/grpc_deps.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -374,11 +374,11 @@ def grpc_deps():
if "envoy_api" not in native.existing_rules():
http_archive(
name = "envoy_api",
sha256 = "0fe4c68dea4423f5880c068abbcbc90ac4b98496cf2af15a1fe3fbc0fdb050fd",
strip_prefix = "data-plane-api-bf6154e482bbd5e6f64032993206e66b6116f2bd",
sha256 = "08f7828a7ae288ef379db9b7f57af73d77a817c22fd0fc42093a95be3e54194a",
strip_prefix = "data-plane-api-5962b1204f4b7b0a2ed7622d0149727f602ae74c",
urls = [
"https://storage.googleapis.com/grpc-bazel-mirror/github.com/envoyproxy/data-plane-api/archive/bf6154e482bbd5e6f64032993206e66b6116f2bd.tar.gz",
"https://github.com/envoyproxy/data-plane-api/archive/bf6154e482bbd5e6f64032993206e66b6116f2bd.tar.gz",
"https://storage.googleapis.com/grpc-bazel-mirror/github.com/envoyproxy/data-plane-api/archive/5962b1204f4b7b0a2ed7622d0149727f602ae74c.tar.gz",
"https://github.com/envoyproxy/data-plane-api/archive/5962b1204f4b7b0a2ed7622d0149727f602ae74c.tar.gz",
],
)

Expand Down
Loading

0 comments on commit 8a02496

Please sign in to comment.