66 lines
2.4 KiB
Protocol Buffer
66 lines
2.4 KiB
Protocol Buffer
|
|
// This file was autogenerated by go-to-protobuf. Do not edit it manually!
|
|
|
|
syntax = "proto2";
|
|
|
|
package github.com.karmada_io.karmada.pkg.estimator.pb;
|
|
|
|
import "k8s.io/api/core/v1/generated.proto";
|
|
import "k8s.io/apimachinery/pkg/api/resource/generated.proto";
|
|
|
|
// Package-wide variables from generator "generated".
|
|
option go_package = "pb";
|
|
|
|
// MaxAvailableReplicasRequest represents the request that sent by gRPC client to calculate max available replicas.
|
|
message MaxAvailableReplicasRequest {
|
|
// Cluster represents the cluster name.
|
|
// +required
|
|
optional string cluster = 1;
|
|
|
|
// ReplicaRequirements represents the requirements required by each replica.
|
|
// +required
|
|
optional ReplicaRequirements replicaRequirements = 2;
|
|
}
|
|
|
|
// MaxAvailableReplicasResponse represents the response that sent by gRPC server to calculate max available replicas.
|
|
message MaxAvailableReplicasResponse {
|
|
// MaxReplicas represents the max replica that the cluster can produce.
|
|
// +required
|
|
optional int32 maxReplicas = 1;
|
|
}
|
|
|
|
// NodeClaim represents the NodeAffinity, NodeSelector and Tolerations required by each replica.
|
|
message NodeClaim {
|
|
// A node selector represents the union of the results of one or more label queries over a set of
|
|
// nodes; that is, it represents the OR of the selectors represented by the node selector terms.
|
|
// Note that only PodSpec.Affinity.NodeAffinity.RequiredDuringSchedulingIgnoredDuringExecution
|
|
// is included here because it has a hard limit on pod scheduling.
|
|
// +optional
|
|
optional k8s.io.api.core.v1.NodeSelector nodeAffinity = 1;
|
|
|
|
// NodeSelector is a selector which must be true for the pod to fit on a node.
|
|
// Selector which must match a node's labels for the pod to be scheduled on that node.
|
|
// +optional
|
|
map<string, string> nodeSelector = 2;
|
|
|
|
// If specified, the pod's tolerations.
|
|
// +optional
|
|
repeated k8s.io.api.core.v1.Toleration tolerations = 3;
|
|
}
|
|
|
|
// ReplicaRequirements represents the requirements required by each replica.
|
|
message ReplicaRequirements {
|
|
// NodeClaim represents the NodeAffinity, NodeSelector and Tolerations required by each replica.
|
|
// +optional
|
|
optional NodeClaim nodeClaim = 1;
|
|
|
|
// ResourceRequest represents the resources required by each replica.
|
|
// +optional
|
|
map<string, k8s.io.apimachinery.pkg.api.resource.Quantity> resourceRequest = 2;
|
|
}
|
|
|
|
// UnimplementedEstimatorServer can be embedded to have forward compatible implementations.
|
|
message UnimplementedEstimatorServer {
|
|
}
|
|
|