|
| 1 | +syntax = "proto3"; |
| 2 | + |
| 3 | +package envoy.extensions.load_balancing_policies.load_aware_locality.v3; |
| 4 | + |
| 5 | +import "envoy/config/cluster/v3/cluster.proto"; |
| 6 | + |
| 7 | +import "google/protobuf/duration.proto"; |
| 8 | +import "google/protobuf/wrappers.proto"; |
| 9 | + |
| 10 | +import "udpa/annotations/status.proto"; |
| 11 | +import "validate/validate.proto"; |
| 12 | + |
| 13 | +option java_package = "io.envoyproxy.envoy.extensions.load_balancing_policies.load_aware_locality.v3"; |
| 14 | +option java_outer_classname = "LoadAwareLocalityProto"; |
| 15 | +option java_multiple_files = true; |
| 16 | +option go_package = "github.com/envoyproxy/go-control-plane/envoy/extensions/load_balancing_policies/load_aware_locality/v3;load_aware_localityv3"; |
| 17 | +option (udpa.annotations.file_status).package_version_status = ACTIVE; |
| 18 | + |
| 19 | +// [#protodoc-title: Load-Aware Locality-Picking Load Balancing Policy] |
| 20 | +// [#extension: envoy.load_balancing_policies.load_aware_locality] |
| 21 | + |
| 22 | +// Configuration for the load_aware_locality LB policy which uses ORCA utilization data |
| 23 | +// to route traffic between localities based on available headroom. |
| 24 | +// [#next-free-field: 8] |
| 25 | +message LoadAwareLocality { |
| 26 | + // The child LB policy to create for endpoint-picking within each locality. |
| 27 | + config.cluster.v3.LoadBalancingPolicy endpoint_picking_policy = 1 |
| 28 | + [(validate.rules).message = {required: true}]; |
| 29 | + |
| 30 | + // How frequently ORCA weights and locality utilization are recomputed on the |
| 31 | + // main thread. Defaults to 1s. |
| 32 | + google.protobuf.Duration weight_update_period = 2; |
| 33 | + |
| 34 | + // Named metrics from ORCA reports to use for computing utilization. |
| 35 | + // When configured, endpoint utilization is computed by taking the max of the |
| 36 | + // values of these metrics. For map fields in the ORCA proto, the string will |
| 37 | + // be of the form ``<map_field_name>.<map_key>``. For example, the string |
| 38 | + // ``named_metrics.foo`` will look for the key ``foo`` in the ORCA |
| 39 | + // :ref:`named_metrics <envoy_v3_api_field_.xds.data.orca.v3.OrcaLoadReport.named_metrics>` |
| 40 | + // field. If this field is not configured or none of the specified metrics are |
| 41 | + // present in the load report, then |
| 42 | + // :ref:`application_utilization <envoy_v3_api_field_.xds.data.orca.v3.OrcaLoadReport.application_utilization>` |
| 43 | + // is used instead. If that field is also not set or is zero, then |
| 44 | + // :ref:`cpu_utilization <envoy_v3_api_field_.xds.data.orca.v3.OrcaLoadReport.cpu_utilization>` |
| 45 | + // is used. |
| 46 | + repeated string metric_names_for_computing_utilization = 3; |
| 47 | + |
| 48 | + // When the local locality's utilization is at most this threshold above the |
| 49 | + // remote average, route 100% of traffic to the local locality. This avoids |
| 50 | + // unnecessary cross-zone routing when utilization is roughly balanced. |
| 51 | + // Must be in [0, 1]. Defaults to 0.1. |
| 52 | + google.protobuf.DoubleValue utilization_variance_threshold = 4 |
| 53 | + [(validate.rules).double = {lte: 1.0 gte: 0.0}]; |
| 54 | + |
| 55 | + // EWMA smoothing factor for per-locality utilization. Must be in (0, 1]. |
| 56 | + // Higher values react faster to changes, lower values are more stable. |
| 57 | + // Defaults to 0.3. |
| 58 | + google.protobuf.DoubleValue ewma_alpha = 5 [(validate.rules).double = {lte: 1.0 gt: 0.0}]; |
| 59 | + |
| 60 | + // Minimum fraction of traffic sent to non-local localities to keep |
| 61 | + // ORCA data fresh. Applied even in all_local mode. Must be in [0, 1). |
| 62 | + // Set to 0 to disable. Defaults to 0.03 (3%). |
| 63 | + google.protobuf.DoubleValue probe_percentage = 6 [(validate.rules).double = {lt: 1.0 gte: 0.0}]; |
| 64 | + |
| 65 | + // If a given endpoint has not reported load metrics in this long, then we |
| 66 | + // stop using the reported weight. This ensures that we do not continue to |
| 67 | + // use very stale weights. Set to 0s to disable expiration. Defaults to 3 minutes. |
| 68 | + google.protobuf.Duration weight_expiration_period = 7 [(validate.rules).duration = {gte {}}]; |
| 69 | +} |
0 commit comments