Skip to content

Commit

Permalink
move deprecated protos to the end of the file
Browse files Browse the repository at this point in the history
  • Loading branch information
markdroth committed Jan 23, 2024
1 parent 16b395a commit 443921c
Showing 1 changed file with 172 additions and 167 deletions.
339 changes: 172 additions & 167 deletions grpc/service_config/service_config.proto
Original file line number Diff line number Diff line change
Expand Up @@ -317,7 +317,7 @@ message OutlierDetectionLoadBalancingConfig {

// If set, success rate ejections will be performed
SuccessRateEjection success_rate_ejection = 5;

// If set, failure rate ejections will be performed
FailurePercentageEjection failure_percentage_ejection = 6;

Expand Down Expand Up @@ -398,89 +398,6 @@ message CdsConfig {
bool is_dynamic = 2;
}

// Represents an xDS server.
message XdsServer {
string server_uri = 1 [json_name = "server_uri"]; // Required.

message ChannelCredentials {
string type = 1; // Required.
google.protobuf.Struct config = 2; // Optional JSON config.
}
// A list of channel creds to use. The first supported type will be used.
repeated ChannelCredentials channel_creds = 2 [json_name = "channel_creds"];

// A repeated list of server features.
repeated google.protobuf.Value server_features = 3
[json_name = "server_features"];
}

// Configuration for xds_cluster_resolver LB policy.
// Deprecated.
message XdsClusterResolverLoadBalancingPolicyConfig {
// Describes a discovery mechanism instance.
// For EDS or LOGICAL_DNS clusters, there will be exactly one
// DiscoveryMechanism, which will describe the cluster of the parent
// CDS policy.
// For aggregate clusters, there will be one DiscoveryMechanism for each
// underlying cluster.
message DiscoveryMechanism {
// Cluster name.
string cluster = 1;

// LRS server to send load reports to.
// If not present, load reporting will be disabled.
// If set to the empty string, load reporting will be sent to the same
// server that we obtained CDS data from.
// DEPRECATED: Use new lrs_load_reporting_server field instead.
google.protobuf.StringValue lrs_load_reporting_server_name = 2
[deprecated=true];

// LRS server to send load reports to.
// If not present, load reporting will be disabled.
// Supercedes lrs_load_reporting_server_name field.
XdsServer lrs_load_reporting_server = 7;

// Maximum number of outstanding requests can be made to the upstream
// cluster. Default is 1024.
google.protobuf.UInt32Value max_concurrent_requests = 3;

enum Type {
UNKNOWN = 0;
EDS = 1;
LOGICAL_DNS = 2;
};
Type type = 4;

// For type EDS only.
// EDS service name, as returned in CDS.
// May be unset if not specified in CDS.
string eds_service_name = 5;

// For type LOGICAL_DNS only.
// DNS name to resolve in "host:port" form.
string dns_hostname = 6;

// The configuration for outlier_detection child policies
// Within this message, the child_policy field will be ignored
OutlierDetectionLoadBalancingConfig outlier_detection = 8;

// The configuration for xds_override_host child policy
repeated OverrideHostLoadBalancingPolicyConfig.HealthStatus override_host_status = 9;

// Telemetry labels associated with this cluster
map<string, string> telemetry_labels = 10;
}

// Ordered list of discovery mechanisms.
// Must have at least one element.
// Results from each discovery mechanism are concatenated together in
// successive priorities.
repeated DiscoveryMechanism discovery_mechanisms = 1;

// xDS LB policy. Will be used as the child config of the xds_cluster_impl LB policy.
repeated LoadBalancingConfig xds_lb_policy = 2;
}

// Configuration for xds_cluster_impl LB policy.
message XdsClusterImplLoadBalancingPolicyConfig {
// Cluster name. Required.
Expand Down Expand Up @@ -524,37 +441,6 @@ message XdsClusterImplLoadBalancingPolicyConfig {
map<string, string> telemetry_labels = 8 [deprecated = true];
}

// Configuration for eds LB policy.
// Deprecated.
message EdsLoadBalancingPolicyConfig {
// Cluster name. Required.
string cluster = 1;

// EDS service name, as returned in CDS.
// May be unset if not specified in CDS.
string eds_service_name = 2;

// Server to send load reports to.
// If unset, no load reporting is done.
// If set to empty string, load reporting will be sent to the same
// server as we are getting xds data from.
google.protobuf.StringValue lrs_load_reporting_server_name = 3;

// Locality-picking policy.
// This policy's config is expected to be in the format used
// by the weighted_target policy. Note that the config should include
// an empty value for the "targets" field; that empty value will be
// replaced by one that is dynamically generated based on the EDS data.
// Optional; defaults to "weighted_target".
repeated LoadBalancingConfig locality_picking_policy = 4;

// Endpoint-picking policy.
// This will be configured as the policy for each child in the
// locality-policy's config.
// Optional; defaults to "round_robin".
repeated LoadBalancingConfig endpoint_picking_policy = 5;
}

// Configuration for ring_hash LB policy.
message RingHashLoadBalancingConfig {
// A client-side option will cap these values to 4096. If either of these
Expand All @@ -564,33 +450,6 @@ message RingHashLoadBalancingConfig {
uint64 max_ring_size = 2; // Optional, defaults to 4096, max 8M.
}

// Configuration for lrs LB policy.
// Deprecated.
message LrsLoadBalancingPolicyConfig {
// Cluster name. Required.
string cluster_name = 1;

// EDS service name, as returned in CDS.
// May be unset if not specified in CDS.
string eds_service_name = 2;

// Server to send load reports to. Required.
// If set to empty string, load reporting will be sent to the same
// server as we are getting xds data from.
string lrs_load_reporting_server_name = 3;

// The locality for which this policy will report load. Required.
message Locality {
string region = 1;
string zone = 2;
string subzone = 3;
}
Locality locality = 4;

// Endpoint-picking policy.
repeated LoadBalancingConfig child_policy = 5;
}

// Configuration for the xds_wrr_locality load balancing policy.
message XdsWrrLocalityLoadBalancingPolicyConfig {
repeated LoadBalancingConfig child_policy = 1;
Expand All @@ -617,31 +476,6 @@ message OverrideHostLoadBalancingPolicyConfig {
repeated HealthStatus override_host_status = 1 [deprecated = true];
}

// Configuration for xds LB policy.
// Deprecated.
message XdsConfig {
// Name of balancer to connect to.
string balancer_name = 1 [deprecated = true];
// Optional. What LB policy to use for intra-locality routing.
// If unset, will use whatever algorithm is specified by the balancer.
// Multiple LB policies can be specified; clients will iterate through
// the list in order and stop at the first policy that they support.
repeated LoadBalancingConfig child_policy = 2;
// Optional. What LB policy to use in fallback mode. If not
// specified, defaults to round_robin.
// Multiple LB policies can be specified; clients will iterate through
// the list in order and stop at the first policy that they support.
repeated LoadBalancingConfig fallback_policy = 3;
// Optional. Name to use in EDS query. If not present, defaults to
// the server name from the target URI.
string eds_service_name = 4;
// LRS server to send load reports to.
// If not present, load reporting will be disabled.
// If set to the empty string, load reporting will be sent to the same
// server that we obtained CDS data from.
google.protobuf.StringValue lrs_load_reporting_server_name = 5;
}

// Selects LB policy and provides corresponding configuration.
//
// In general, all instances of this field should be repeated. Clients will
Expand Down Expand Up @@ -795,3 +629,174 @@ message ServiceConfig {

// next available tag: 6
}

//
// DEPRECATED MESSAGES -- DO NOT USE
//

// Represents an xDS server.
// Deprecated.
message XdsServer {
string server_uri = 1 [json_name = "server_uri"]; // Required.

message ChannelCredentials {
string type = 1; // Required.
google.protobuf.Struct config = 2; // Optional JSON config.
}
// A list of channel creds to use. The first supported type will be used.
repeated ChannelCredentials channel_creds = 2 [json_name = "channel_creds"];

// A repeated list of server features.
repeated google.protobuf.Value server_features = 3
[json_name = "server_features"];
}

// Configuration for xds_cluster_resolver LB policy.
// Deprecated.
message XdsClusterResolverLoadBalancingPolicyConfig {
// Describes a discovery mechanism instance.
// For EDS or LOGICAL_DNS clusters, there will be exactly one
// DiscoveryMechanism, which will describe the cluster of the parent
// CDS policy.
// For aggregate clusters, there will be one DiscoveryMechanism for each
// underlying cluster.
message DiscoveryMechanism {
// Cluster name.
string cluster = 1;

// LRS server to send load reports to.
// If not present, load reporting will be disabled.
// If set to the empty string, load reporting will be sent to the same
// server that we obtained CDS data from.
// DEPRECATED: Use new lrs_load_reporting_server field instead.
google.protobuf.StringValue lrs_load_reporting_server_name = 2
[deprecated=true];

// LRS server to send load reports to.
// If not present, load reporting will be disabled.
// Supercedes lrs_load_reporting_server_name field.
XdsServer lrs_load_reporting_server = 7;

// Maximum number of outstanding requests can be made to the upstream
// cluster. Default is 1024.
google.protobuf.UInt32Value max_concurrent_requests = 3;

enum Type {
UNKNOWN = 0;
EDS = 1;
LOGICAL_DNS = 2;
};
Type type = 4;

// For type EDS only.
// EDS service name, as returned in CDS.
// May be unset if not specified in CDS.
string eds_service_name = 5;

// For type LOGICAL_DNS only.
// DNS name to resolve in "host:port" form.
string dns_hostname = 6;

// The configuration for outlier_detection child policies
// Within this message, the child_policy field will be ignored
OutlierDetectionLoadBalancingConfig outlier_detection = 8;

// The configuration for xds_override_host child policy
repeated OverrideHostLoadBalancingPolicyConfig.HealthStatus override_host_status = 9;

// Telemetry labels associated with this cluster
map<string, string> telemetry_labels = 10;
}

// Ordered list of discovery mechanisms.
// Must have at least one element.
// Results from each discovery mechanism are concatenated together in
// successive priorities.
repeated DiscoveryMechanism discovery_mechanisms = 1;

// xDS LB policy. Will be used as the child config of the xds_cluster_impl LB policy.
repeated LoadBalancingConfig xds_lb_policy = 2;
}

// Configuration for lrs LB policy.
// Deprecated.
message LrsLoadBalancingPolicyConfig {
// Cluster name. Required.
string cluster_name = 1;

// EDS service name, as returned in CDS.
// May be unset if not specified in CDS.
string eds_service_name = 2;

// Server to send load reports to. Required.
// If set to empty string, load reporting will be sent to the same
// server as we are getting xds data from.
string lrs_load_reporting_server_name = 3;

// The locality for which this policy will report load. Required.
message Locality {
string region = 1;
string zone = 2;
string subzone = 3;
}
Locality locality = 4;

// Endpoint-picking policy.
repeated LoadBalancingConfig child_policy = 5;
}

// Configuration for eds LB policy.
// Deprecated.
message EdsLoadBalancingPolicyConfig {
// Cluster name. Required.
string cluster = 1;

// EDS service name, as returned in CDS.
// May be unset if not specified in CDS.
string eds_service_name = 2;

// Server to send load reports to.
// If unset, no load reporting is done.
// If set to empty string, load reporting will be sent to the same
// server as we are getting xds data from.
google.protobuf.StringValue lrs_load_reporting_server_name = 3;

// Locality-picking policy.
// This policy's config is expected to be in the format used
// by the weighted_target policy. Note that the config should include
// an empty value for the "targets" field; that empty value will be
// replaced by one that is dynamically generated based on the EDS data.
// Optional; defaults to "weighted_target".
repeated LoadBalancingConfig locality_picking_policy = 4;

// Endpoint-picking policy.
// This will be configured as the policy for each child in the
// locality-policy's config.
// Optional; defaults to "round_robin".
repeated LoadBalancingConfig endpoint_picking_policy = 5;
}

// Configuration for xds LB policy.
// Deprecated.
message XdsConfig {
// Name of balancer to connect to.
string balancer_name = 1 [deprecated = true];
// Optional. What LB policy to use for intra-locality routing.
// If unset, will use whatever algorithm is specified by the balancer.
// Multiple LB policies can be specified; clients will iterate through
// the list in order and stop at the first policy that they support.
repeated LoadBalancingConfig child_policy = 2;
// Optional. What LB policy to use in fallback mode. If not
// specified, defaults to round_robin.
// Multiple LB policies can be specified; clients will iterate through
// the list in order and stop at the first policy that they support.
repeated LoadBalancingConfig fallback_policy = 3;
// Optional. Name to use in EDS query. If not present, defaults to
// the server name from the target URI.
string eds_service_name = 4;
// LRS server to send load reports to.
// If not present, load reporting will be disabled.
// If set to the empty string, load reporting will be sent to the same
// server that we obtained CDS data from.
google.protobuf.StringValue lrs_load_reporting_server_name = 5;
}

0 comments on commit 443921c

Please sign in to comment.