Documentation ¶
Overview ¶
Package v1 contains API Schema definitions for the machinelearning v1 API group +kubebuilder:object:generate=true +groupName=machinelearning.seldon.io
Index ¶
- Constants
- Variables
- func GetContainerForPredictiveUnit(p *PredictorSpec, name string) *corev1.Container
- func GetContainerServiceName(mlDepName string, predictorSpec PredictorSpec, c *v1.Container) string
- func GetDeploymentName(mlDep *SeldonDeployment, predictorSpec PredictorSpec, podSpec *SeldonPodSpec, ...) string
- func GetEnv(key, fallback string) string
- func GetExplainerDeploymentName(sdepName string, predictorSpec *PredictorSpec) string
- func GetPort(name string, ports []corev1.ContainerPort) *corev1.ContainerPort
- func GetPredictorKey(mlDep *SeldonDeployment, p *PredictorSpec) string
- func GetSeldonDeploymentName(mlDep *SeldonDeployment) string
- func GetServiceOrchestratorName(mlDep *SeldonDeployment, p *PredictorSpec) string
- func IsPrepack(pu *PredictiveUnit) bool
- type AlibiExplainerType
- type DeploymentStatus
- type Endpoint
- type EndpointType
- type Explainer
- type Logger
- type LoggerMode
- type ObjectMeta
- type Parameter
- type ParmeterType
- type PredictiveUnit
- type PredictiveUnitImplementation
- type PredictiveUnitMethod
- type PredictiveUnitType
- type PredictorImageConfig
- type PredictorProtocolsConfig
- type PredictorServerConfig
- func (in *PredictorServerConfig) DeepCopy() *PredictorServerConfig
- func (in *PredictorServerConfig) DeepCopyInto(out *PredictorServerConfig)
- func (p *PredictorServerConfig) PrepackImageConfig(protocol Protocol) *PredictorImageConfig
- func (p *PredictorServerConfig) PrepackImageName(protocol Protocol, pu *PredictiveUnit) string
- type PredictorSpec
- type Protocol
- type SSL
- type SeldonAddressable
- type SeldonDeployment
- func (in *SeldonDeployment) DeepCopy() *SeldonDeployment
- func (in *SeldonDeployment) DeepCopyInto(out *SeldonDeployment)
- func (in *SeldonDeployment) DeepCopyObject() runtime.Object
- func (r *SeldonDeployment) Default()
- func (r *SeldonDeployment) SetupWebhookWithManager(mgr ctrl.Manager) error
- func (r *SeldonDeployment) ValidateCreate() error
- func (r *SeldonDeployment) ValidateDelete() error
- func (r *SeldonDeployment) ValidateUpdate(old runtime.Object) error
- type SeldonDeploymentList
- type SeldonDeploymentSpec
- type SeldonDeploymentStatus
- func (ss *SeldonDeploymentStatus) CreateCondition(conditionType apis.ConditionType, isTrue bool, reason string)
- func (in *SeldonDeploymentStatus) DeepCopy() *SeldonDeploymentStatus
- func (in *SeldonDeploymentStatus) DeepCopyInto(out *SeldonDeploymentStatus)
- func (ss *SeldonDeploymentStatus) GetCondition(t apis.ConditionType) *apis.Condition
- func (ss *SeldonDeploymentStatus) InitializeConditions()
- func (ss *SeldonDeploymentStatus) IsConditionReady(t apis.ConditionType) bool
- func (ss *SeldonDeploymentStatus) IsReady() bool
- func (ss *SeldonDeploymentStatus) SetCondition(conditionType apis.ConditionType, condition *apis.Condition)
- type SeldonHpaSpec
- type SeldonPdbSpec
- type SeldonPodSpec
- type SeldonScaledObjectSpec
- type ServerType
- type ServiceStatus
- type StatusState
- type SvcOrchSpec
- type Transport
Constants ¶
const ( EnvSklearnServerImageRelated = "RELATED_IMAGE_SKLEARNSERVER" EnvXgboostserverImageRelated = "RELATED_IMAGE_XGBOOSTSERVER" EnvMlflowserverImageRelated = "RELATED_IMAGE_MLFLOWSERVER" EnvTensorflowImageRelated = "RELATED_IMAGE_TENSORFLOW" EnvTfproxyImageRelated = "RELATED_IMAGE_TFPROXY" PrepackTensorflowName = "TENSORFLOW_SERVER" PrepackSklearnName = "SKLEARN_SERVER" PrepackXgboostName = "XGBOOST_SERVER" PrepackMlflowName = "MLFLOW_SERVER" PrepackTritonName = "TRITON_SERVER" PrepackTempoName = "TEMPO_SERVER" )
const ( DeploymentsReady apis.ConditionType = "DeploymentsReady" ServicesReady apis.ConditionType = "ServicesReady" KedaReady apis.ConditionType = "KedaReady" VirtualServicesReady apis.ConditionType = "istioVirtualServicesReady" HpasReady apis.ConditionType = "HpasReady" PdbsReady apis.ConditionType = "PdbsReady" SvcNotReadyReason string = "Not all services created" SvcReadyReason string = "All services created" KedaNotDefinedReason string = "No KEDA resources defined" KedaNotReadyReason string = "KEDA resources not ready" KedaReadyReason string = "All KEDA resources ready" HpaNotDefinedReason string = "No HPAs defined" HpaNotReadyReason string = "HPAs not ready" HpaReadyReason string = "All HPAs resources ready" PdbNotDefinedReason string = "No PDBs defined" PdbNotReadyReason string = "PDBs not ready" PdbReadyReason string = "All PDBs resources ready" VirtualServiceNotDefined string = "No VirtualServices defined" VirtualServiceNotReady string = "Not all VirtualServices created" VirtualServiceReady string = "All VirtualServices created" )
const ( Label_seldon_id = "seldon-deployment-id" Label_seldon_app = "seldon-app" Label_seldon_app_svc = "seldon-app-svc" Label_svc_orch = "seldon-deployment-contains-svcorch" Label_app = "app" Label_fluentd = "fluentd" Label_router = "seldon.io/router" Label_combiner = "seldon.io/combiner" Label_model = "seldon.io/model" Label_transformer = "seldon.io/transformer" Label_output_transformer = "seldon.io/output-transformer" Label_shadow = "seldon.io/shadow" Label_explainer = "seldon.io/explainer" Label_managed_by = "app.kubernetes.io/managed-by" Label_value_seldon = "seldon-core" PODINFO_VOLUME_NAME = "seldon-podinfo" OLD_PODINFO_VOLUME_NAME = "podinfo" PODINFO_VOLUME_PATH = "/etc/podinfo" ENV_PREDICTIVE_UNIT_SERVICE_PORT = "PREDICTIVE_UNIT_SERVICE_PORT" ENV_PREDICTIVE_UNIT_HTTP_SERVICE_PORT = "PREDICTIVE_UNIT_HTTP_SERVICE_PORT" ENV_PREDICTIVE_UNIT_GRPC_SERVICE_PORT = "PREDICTIVE_UNIT_GRPC_SERVICE_PORT" ENV_PREDICTIVE_UNIT_SERVICE_PORT_METRICS = "PREDICTIVE_UNIT_METRICS_SERVICE_PORT" ENV_PREDICTIVE_UNIT_METRICS_ENDPOINT = "PREDICTIVE_UNIT_METRICS_ENDPOINT" ENV_PREDICTIVE_UNIT_METRICS_PORT_NAME = "PREDICTIVE_UNIT_METRICS_PORT_NAME" ENV_PREDICTIVE_UNIT_PARAMETERS = "PREDICTIVE_UNIT_PARAMETERS" ENV_PREDICTIVE_UNIT_IMAGE = "PREDICTIVE_UNIT_IMAGE" ENV_PREDICTIVE_UNIT_ID = "PREDICTIVE_UNIT_ID" ENV_PREDICTOR_ID = "PREDICTOR_ID" ENV_PREDICTOR_LABELS = "PREDICTOR_LABELS" ENV_SELDON_DEPLOYMENT_ID = "SELDON_DEPLOYMENT_ID" ENV_SELDON_EXECUTOR_ENABLED = "SELDON_EXECUTOR_ENABLED" ENV_DEPLOYMENT_NAME_AS_PREFIX = "DEPLOYMENT_NAME_AS_PREFIX" ANNOTATION_SEPARATE_ENGINE = "seldon.io/engine-separate-pod" ANNOTATION_HEADLESS_SVC = "seldon.io/headless-svc" ANNOTATION_NO_ENGINE = "seldon.io/no-engine" ANNOTATION_CUSTOM_SVC_NAME = "seldon.io/svc-name" ANNOTATION_LOGGER_WORK_QUEUE_SIZE = "seldon.io/executor-logger-queue-size" ANNOTATION_LOGGER_WRITE_TIMEOUT_MS = "seldon.io/executor-logger-write-timeout-ms" DeploymentNamePrefix = "seldon" )
const ( ENV_KAFKA_BROKER = "KAFKA_BROKER" ENV_KAFKA_INPUT_TOPIC = "KAFKA_INPUT_TOPIC" ENV_KAFKA_OUTPUT_TOPIC = "KAFKA_OUTPUT_TOPIC" )
const PredictorServerConfigMapKeyName = "predictor_servers"
Variables ¶
var ( // GroupVersion is group version used to register these objects GroupVersion = schema.GroupVersion{Group: "machinelearning.seldon.io", Version: "v1"} // SchemeBuilder is used to add go types to the GroupVersionKind scheme SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion} // AddToScheme adds the types in this group-version to the given scheme. AddToScheme = SchemeBuilder.AddToScheme // SchemeGroupVersion is group version used to register these objects SchemeGroupVersion = schema.GroupVersion{Group: "machinelearning.seldon.io", Version: "v1"} // Resource takes an unqualified resource and returns a Group qualified GroupResource Resource = func(resource string) schema.GroupResource { return SchemeGroupVersion.WithResource(resource).GroupResource() } )
var ( ControllerNamespace = GetEnv("POD_NAMESPACE", "seldon-system") C client.Client )
var (
ControllerConfigMapName = "seldon-config"
)
Functions ¶
func GetContainerForPredictiveUnit ¶
func GetContainerForPredictiveUnit(p *PredictorSpec, name string) *corev1.Container
func GetContainerServiceName ¶
func GetContainerServiceName(mlDepName string, predictorSpec PredictorSpec, c *v1.Container) string
func GetDeploymentName ¶
func GetDeploymentName(mlDep *SeldonDeployment, predictorSpec PredictorSpec, podSpec *SeldonPodSpec, podSpecIdx int) string
func GetExplainerDeploymentName ¶
func GetExplainerDeploymentName(sdepName string, predictorSpec *PredictorSpec) string
func GetPort ¶
func GetPort(name string, ports []corev1.ContainerPort) *corev1.ContainerPort
func GetPredictorKey ¶
func GetPredictorKey(mlDep *SeldonDeployment, p *PredictorSpec) string
func GetSeldonDeploymentName ¶
func GetSeldonDeploymentName(mlDep *SeldonDeployment) string
func GetServiceOrchestratorName ¶
func GetServiceOrchestratorName(mlDep *SeldonDeployment, p *PredictorSpec) string
func IsPrepack ¶
func IsPrepack(pu *PredictiveUnit) bool
Types ¶
type AlibiExplainerType ¶
type AlibiExplainerType string
const ( AlibiAnchorsTabularExplainer AlibiExplainerType = "AnchorTabular" AlibiAnchorsImageExplainer AlibiExplainerType = "AnchorImages" AlibiAnchorsTextExplainer AlibiExplainerType = "AnchorText" AlibiCounterfactualsExplainer AlibiExplainerType = "Counterfactuals" AlibiContrastiveExplainer AlibiExplainerType = "Contrastive" AlibiKernelShapExplainer AlibiExplainerType = "KernelShap" AlibiIntegratedGradientsExplainer AlibiExplainerType = "IntegratedGradients" AlibiALEExplainer AlibiExplainerType = "ALE" AlibiTreeShap AlibiExplainerType = "TreeShap" )
type DeploymentStatus ¶
type DeploymentStatus struct { Name string `json:"name,omitempty" protobuf:"string,1,opt,name=name"` Status string `json:"status,omitempty" protobuf:"string,2,opt,name=status"` Description string `json:"description,omitempty" protobuf:"string,3,opt,name=description"` Replicas int32 `json:"replicas,omitempty" protobuf:"string,4,opt,name=replicas"` AvailableReplicas int32 `json:"availableReplicas,omitempty" protobuf:"string,5,opt,name=availableRelicas"` ExplainerFor string `json:"explainerFor,omitempty" protobuf:"string,6,opt,name=explainerFor"` }
func (*DeploymentStatus) DeepCopy ¶
func (in *DeploymentStatus) DeepCopy() *DeploymentStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DeploymentStatus.
func (*DeploymentStatus) DeepCopyInto ¶
func (in *DeploymentStatus) DeepCopyInto(out *DeploymentStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Endpoint ¶
type Endpoint struct { ServiceHost string `json:"service_host,omitempty" protobuf:"string,1,opt,name=service_host"` ServicePort int32 `json:"service_port,omitempty" protobuf:"int32,2,opt,name=service_port"` Type EndpointType `json:"type,omitempty" protobuf:"int,3,opt,name=type"` HttpPort int32 `json:"httpPort,omitempty" protobuf:"int32,4,opt,name=httpPort"` GrpcPort int32 `json:"grpcPort,omitempty" protobuf:"int32,5,opt,name=grpcPort"` }
func (*Endpoint) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Endpoint.
func (*Endpoint) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type EndpointType ¶
type EndpointType string
const ( REST EndpointType = "REST" GRPC EndpointType = "GRPC" )
type Explainer ¶
type Explainer struct { Type AlibiExplainerType `json:"type,omitempty" protobuf:"string,1,opt,name=type"` ModelUri string `json:"modelUri,omitempty" protobuf:"string,2,opt,name=modelUri"` ServiceAccountName string `json:"serviceAccountName,omitempty" protobuf:"string,3,opt,name=serviceAccountName"` ContainerSpec v1.Container `json:"containerSpec,omitempty" protobuf:"bytes,4,opt,name=containerSpec"` Config map[string]string `json:"config,omitempty" protobuf:"bytes,5,opt,name=config"` Endpoint *Endpoint `json:"endpoint,omitempty" protobuf:"bytes,6,opt,name=endpoint"` EnvSecretRefName string `json:"envSecretRefName,omitempty" protobuf:"bytes,7,opt,name=envSecretRefName"` StorageInitializerImage string `json:"storageInitializerImage,omitempty" protobuf:"bytes,8,opt,name=storageInitializerImage"` Replicas *int32 `json:"replicas,omitempty" protobuf:"string,9,opt,name=replicas"` InitParameters string `json:"initParameters,omitempty" protobuf:"string,10,opt,name=initParameters"` }
func (*Explainer) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Explainer.
func (*Explainer) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Logger ¶
type Logger struct { // URL to send request logging CloudEvents // +optional Url *string `json:"url,omitempty"` // What payloads to log Mode LoggerMode `json:"mode,omitempty"` }
Logger provides optional payload logging for all endpoints +experimental
func (*Logger) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Logger.
func (*Logger) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LoggerMode ¶
type LoggerMode string
const ( LogAll LoggerMode = "all" LogRequest LoggerMode = "request" LogResponse LoggerMode = "response" )
type ObjectMeta ¶
type ObjectMeta struct { // Name must be unique within a namespace. Is required when creating resources, although // some resources may allow a client to request the generation of an appropriate name // automatically. Name is primarily intended for creation idempotence and configuration // definition. // Cannot be updated. // More info: http://kubernetes.io/docs/user-guide/identifiers#names // +optional Name string `json:"name,omitempty" protobuf:"bytes,1,opt,name=name"` // GenerateName is an optional prefix, used by the server, to generate a unique // name ONLY IF the Name field has not been provided. // If this field is used, the name returned to the client will be different // than the name passed. This value will also be combined with a unique suffix. // The provided value has the same validation rules as the Name field, // and may be truncated by the length of the suffix required to make the value // unique on the server. // // If this field is specified and the generated name exists, the server will // NOT return a 409 - instead, it will either return 201 Created or 500 with Reason // ServerTimeout indicating a unique name could not be found in the time allotted, and the client // should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#idempotency // +optional GenerateName string `json:"generateName,omitempty" protobuf:"bytes,2,opt,name=generateName"` // Namespace defines the space within each name must be unique. An empty namespace is // equivalent to the "default" namespace, but "default" is the canonical representation. // Not all objects are required to be scoped to a namespace - the value of this field for // those objects will be empty. // // Must be a DNS_LABEL. // Cannot be updated. // More info: http://kubernetes.io/docs/user-guide/namespaces // +optional Namespace string `json:"namespace,omitempty" protobuf:"bytes,3,opt,name=namespace"` // SelfLink is a URL representing this object. // Populated by the system. // Read-only. // // DEPRECATED // Kubernetes will stop propagating this field in 1.20 release and the field is planned // to be removed in 1.21 release. // +optional SelfLink string `json:"selfLink,omitempty" protobuf:"bytes,4,opt,name=selfLink"` // UID is the unique in time and space value for this object. It is typically generated by // the server on successful creation of a resource and is not allowed to change on PUT // operations. // // Populated by the system. // Read-only. // More info: http://kubernetes.io/docs/user-guide/identifiers#uids // +optional UID types.UID `json:"uid,omitempty" protobuf:"bytes,5,opt,name=uid,casttype=k8s.io/kubernetes/pkg/types.UID"` // An opaque value that represents the internal version of this object that can // be used by clients to determine when objects have changed. May be used for optimistic // concurrency, change detection, and the watch operation on a resource or set of resources. // Clients must treat these values as opaque and passed unmodified back to the server. // They may only be valid for a particular resource or set of resources. // // Populated by the system. // Read-only. // Value must be treated as opaque by clients and . // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency // +optional ResourceVersion string `json:"resourceVersion,omitempty" protobuf:"bytes,6,opt,name=resourceVersion"` // A sequence number representing a specific generation of the desired state. // Populated by the system. Read-only. // +optional Generation int64 `json:"generation,omitempty" protobuf:"varint,7,opt,name=generation"` // CreationTimestamp is a timestamp representing the server time when this object was // created. It is not guaranteed to be set in happens-before order across separate operations. // Clients may not set this value. It is represented in RFC3339 form and is in UTC. // // Populated by the system. // Read-only. // Null for lists. // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata // +optional // +nullable CreationTimestamp *metav1.Time `json:"creationTimestamp,omitempty" protobuf:"bytes,8,opt,name=creationTimestamp"` // DeletionTimestamp is RFC 3339 date and time at which this resource will be deleted. This // field is set by the server when a graceful deletion is requested by the user, and is not // directly settable by a client. The resource is expected to be deleted (no longer visible // from resource lists, and not reachable by name) after the time in this field, once the // finalizers list is empty. As long as the finalizers list contains items, deletion is blocked. // Once the deletionTimestamp is set, this value may not be unset or be set further into the // future, although it may be shortened or the resource may be deleted prior to this time. // For example, a user may request that a pod is deleted in 30 seconds. The Kubelet will react // by sending a graceful termination signal to the containers in the pod. After that 30 seconds, // the Kubelet will send a hard termination signal (SIGKILL) to the container and after cleanup, // remove the pod from the API. In the presence of network partitions, this object may still // exist after this timestamp, until an administrator or automated process can determine the // resource is fully terminated. // If not set, graceful deletion of the object has not been requested. // // Populated by the system when a graceful deletion is requested. // Read-only. // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata // +optional DeletionTimestamp *metav1.Time `json:"deletionTimestamp,omitempty" protobuf:"bytes,9,opt,name=deletionTimestamp"` // Number of seconds allowed for this object to gracefully terminate before // it will be removed from the system. Only set when deletionTimestamp is also set. // May only be shortened. // Read-only. // +optional DeletionGracePeriodSeconds *int64 `json:"deletionGracePeriodSeconds,omitempty" protobuf:"varint,10,opt,name=deletionGracePeriodSeconds"` // Map of string keys and values that can be used to organize and categorize // (scope and select) objects. May match selectors of replication controllers // and services. // More info: http://kubernetes.io/docs/user-guide/labels // +optional Labels map[string]string `json:"labels,omitempty" protobuf:"bytes,11,rep,name=labels"` // Annotations is an unstructured key value map stored with a resource that may be // set by external tools to store and retrieve arbitrary metadata. They are not // queryable and should be preserved when modifying objects. // More info: http://kubernetes.io/docs/user-guide/annotations // +optional Annotations map[string]string `json:"annotations,omitempty" protobuf:"bytes,12,rep,name=annotations"` // List of objects depended by this object. If ALL objects in the list have // been deleted, this object will be garbage collected. If this object is managed by a controller, // then an entry in this list will point to this controller, with the controller field set to true. // There cannot be more than one managing controller. // +optional // +patchMergeKey=uid // +patchStrategy=merge OwnerReferences []metav1.OwnerReference `json:"ownerReferences,omitempty" patchStrategy:"merge" patchMergeKey:"uid" protobuf:"bytes,13,rep,name=ownerReferences"` // Must be empty before the object is deleted from the registry. Each entry // is an identifier for the responsible component that will remove the entry // from the list. If the deletionTimestamp of the object is non-nil, entries // in this list can only be removed. // Finalizers may be processed and removed in any order. Order is NOT enforced // because it introduces significant risk of stuck finalizers. // finalizers is a shared field, any actor with permission can reorder it. // If the finalizer list is processed in order, then this can lead to a situation // in which the component responsible for the first finalizer in the list is // waiting for a signal (field value, external system, or other) produced by a // component responsible for a finalizer later in the list, resulting in a deadlock. // Without enforced ordering finalizers are free to order amongst themselves and // are not vulnerable to ordering changes in the list. // +optional // +patchStrategy=merge Finalizers []string `json:"finalizers,omitempty" patchStrategy:"merge" protobuf:"bytes,14,rep,name=finalizers"` // The name of the cluster which the object belongs to. // This is used to distinguish resources with same name and namespace in different clusters. // This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. // +optional ClusterName string `json:"clusterName,omitempty" protobuf:"bytes,15,opt,name=clusterName"` }
ObjectMeta is a copy of the "k8s.io/apimachinery/pkg/apis/meta/v1" ObjectMeta. We copy it for 2 reasons: * to be included in the structural schema of the CRD. * to edit the CreationTimestamp to be nullable and a pointer to metav1.Time instead of a struct which allows better serialization. * remove ManagedFields which contain unsupported "Any" type.
func (*ObjectMeta) DeepCopy ¶
func (in *ObjectMeta) DeepCopy() *ObjectMeta
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ObjectMeta.
func (*ObjectMeta) DeepCopyInto ¶
func (in *ObjectMeta) DeepCopyInto(out *ObjectMeta)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Parameter ¶
type Parameter struct { Name string `json:"name" protobuf:"string,1,opt,name=name"` Value string `json:"value" protobuf:"string,2,opt,name=value"` Type ParmeterType `json:"type" protobuf:"int,3,opt,name=type"` }
func (*Parameter) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Parameter.
func (*Parameter) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ParmeterType ¶
type ParmeterType string
const ( INT ParmeterType = "INT" FLOAT ParmeterType = "FLOAT" DOUBLE ParmeterType = "DOUBLE" STRING ParmeterType = "STRING" BOOL ParmeterType = "BOOL" )
type PredictiveUnit ¶
type PredictiveUnit struct { Name string `json:"name" protobuf:"string,1,opt,name=name"` Children []PredictiveUnit `json:"children,omitempty" protobuf:"bytes,2,opt,name=children"` Type *PredictiveUnitType `json:"type,omitempty" protobuf:"int,3,opt,name=type"` Implementation *PredictiveUnitImplementation `json:"implementation,omitempty" protobuf:"int,4,opt,name=implementation"` Methods *[]PredictiveUnitMethod `json:"methods,omitempty" protobuf:"int,5,opt,name=methods"` Endpoint *Endpoint `json:"endpoint,omitempty" protobuf:"bytes,6,opt,name=endpoint"` Parameters []Parameter `json:"parameters,omitempty" protobuf:"bytes,7,opt,name=parameters"` ModelURI string `json:"modelUri,omitempty" protobuf:"bytes,8,opt,name=modelUri"` ServiceAccountName string `json:"serviceAccountName,omitempty" protobuf:"bytes,9,opt,name=serviceAccountName"` EnvSecretRefName string `json:"envSecretRefName,omitempty" protobuf:"bytes,10,opt,name=envSecretRefName"` StorageInitializerImage string `json:"storageInitializerImage,omitempty" protobuf:"bytes,11,opt,name=storageInitializerImage"` Logger *Logger `json:"logger,omitempty" protobuf:"bytes,12,opt,name=logger"` }
func GetEnginePredictiveUnit ¶
func GetEnginePredictiveUnit(pu *PredictiveUnit) *PredictiveUnit
if engine is not separated then this tells us which pu it should go on, as the mutating webhook handler has set host as localhost on the pu
func GetPredictiveUnit ¶
func GetPredictiveUnit(pu *PredictiveUnit, name string) *PredictiveUnit
func GetPredictiveUnitList ¶
func GetPredictiveUnitList(p *PredictiveUnit) (list []*PredictiveUnit)
func (*PredictiveUnit) DeepCopy ¶
func (in *PredictiveUnit) DeepCopy() *PredictiveUnit
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PredictiveUnit.
func (*PredictiveUnit) DeepCopyInto ¶
func (in *PredictiveUnit) DeepCopyInto(out *PredictiveUnit)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type PredictiveUnitImplementation ¶
type PredictiveUnitImplementation string
const ( UNKNOWN_IMPLEMENTATION PredictiveUnitImplementation = "UNKNOWN_IMPLEMENTATION" SIMPLE_MODEL PredictiveUnitImplementation = "SIMPLE_MODEL" SIMPLE_ROUTER PredictiveUnitImplementation = "SIMPLE_ROUTER" RANDOM_ABTEST PredictiveUnitImplementation = "RANDOM_ABTEST" AVERAGE_COMBINER PredictiveUnitImplementation = "AVERAGE_COMBINER" )
type PredictiveUnitMethod ¶
type PredictiveUnitMethod string
const ( TRANSFORM_INPUT PredictiveUnitMethod = "TRANSFORM_INPUT" TRANSFORM_OUTPUT PredictiveUnitMethod = "TRANSFORM_OUTPUT" ROUTE PredictiveUnitMethod = "ROUTE" AGGREGATE PredictiveUnitMethod = "AGGREGATE" SEND_FEEDBACK PredictiveUnitMethod = "SEND_FEEDBACK" )
type PredictiveUnitType ¶
type PredictiveUnitType string
const ( UNKNOWN_TYPE PredictiveUnitType = "UNKNOWN_TYPE" ROUTER PredictiveUnitType = "ROUTER" COMBINER PredictiveUnitType = "COMBINER" MODEL PredictiveUnitType = "MODEL" TRANSFORMER PredictiveUnitType = "TRANSFORMER" OUTPUT_TRANSFORMER PredictiveUnitType = "OUTPUT_TRANSFORMER" )
type PredictorImageConfig ¶
type PredictorImageConfig struct { ContainerImage string `json:"image"` DefaultImageVersion string `json:"defaultImageVersion"` }
func (*PredictorImageConfig) DeepCopy ¶
func (in *PredictorImageConfig) DeepCopy() *PredictorImageConfig
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PredictorImageConfig.
func (*PredictorImageConfig) DeepCopyInto ¶
func (in *PredictorImageConfig) DeepCopyInto(out *PredictorImageConfig)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type PredictorProtocolsConfig ¶
type PredictorProtocolsConfig struct { Seldon *PredictorImageConfig `json:"seldon,omitempty"` KFServing *PredictorImageConfig `json:"kfserving,omitempty"` Tensorflow *PredictorImageConfig `json:"tensorflow,omitempty"` }
func (*PredictorProtocolsConfig) DeepCopy ¶
func (in *PredictorProtocolsConfig) DeepCopy() *PredictorProtocolsConfig
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PredictorProtocolsConfig.
func (*PredictorProtocolsConfig) DeepCopyInto ¶
func (in *PredictorProtocolsConfig) DeepCopyInto(out *PredictorProtocolsConfig)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type PredictorServerConfig ¶
type PredictorServerConfig struct {
Protocols map[Protocol]PredictorImageConfig `json:"protocols"`
}
func GetPrepackServerConfig ¶
func GetPrepackServerConfig(serverName string) *PredictorServerConfig
func (*PredictorServerConfig) DeepCopy ¶
func (in *PredictorServerConfig) DeepCopy() *PredictorServerConfig
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PredictorServerConfig.
func (*PredictorServerConfig) DeepCopyInto ¶
func (in *PredictorServerConfig) DeepCopyInto(out *PredictorServerConfig)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*PredictorServerConfig) PrepackImageConfig ¶
func (p *PredictorServerConfig) PrepackImageConfig(protocol Protocol) *PredictorImageConfig
func (*PredictorServerConfig) PrepackImageName ¶
func (p *PredictorServerConfig) PrepackImageName(protocol Protocol, pu *PredictiveUnit) string
type PredictorSpec ¶
type PredictorSpec struct { Name string `json:"name" protobuf:"string,1,opt,name=name"` Graph PredictiveUnit `json:"graph" protobuf:"bytes,2,opt,name=predictiveUnit"` ComponentSpecs []*SeldonPodSpec `json:"componentSpecs,omitempty" protobuf:"bytes,3,opt,name=componentSpecs"` Replicas *int32 `json:"replicas,omitempty" protobuf:"string,4,opt,name=replicas"` Annotations map[string]string `json:"annotations,omitempty" protobuf:"bytes,5,opt,name=annotations"` EngineResources v1.ResourceRequirements `json:"engineResources,omitempty" protobuf:"bytes,6,opt,name=engineResources"` Labels map[string]string `json:"labels,omitempty" protobuf:"bytes,7,opt,name=labels"` SvcOrchSpec SvcOrchSpec `json:"svcOrchSpec,omitempty" protobuf:"bytes,8,opt,name=svcOrchSpec"` Traffic int32 `json:"traffic,omitempty" protobuf:"bytes,9,opt,name=traffic"` Explainer *Explainer `json:"explainer,omitempty" protobuf:"bytes,10,opt,name=explainer"` Shadow bool `json:"shadow,omitempty" protobuf:"bytes,11,opt,name=shadow"` SSL *SSL `json:"ssl,omitempty" protobuf:"bytes,12,opt,name=ssl"` }
func (*PredictorSpec) DeepCopy ¶
func (in *PredictorSpec) DeepCopy() *PredictorSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PredictorSpec.
func (*PredictorSpec) DeepCopyInto ¶
func (in *PredictorSpec) DeepCopyInto(out *PredictorSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SSL ¶
type SSL struct {
CertSecretName string `json:"certSecretName,omitempty" protobuf:"string,2,opt,name=certSecretName"`
}
func (*SSL) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SSL.
func (*SSL) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SeldonAddressable ¶
type SeldonAddressable struct {
URL string `json:"url,omitempty"`
}
Addressable placeholder until duckv1 issue is fixed:
https://github.com/kubernetes-sigs/controller-tools/issues/391
func (*SeldonAddressable) DeepCopy ¶
func (in *SeldonAddressable) DeepCopy() *SeldonAddressable
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SeldonAddressable.
func (*SeldonAddressable) DeepCopyInto ¶
func (in *SeldonAddressable) DeepCopyInto(out *SeldonAddressable)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SeldonDeployment ¶
type SeldonDeployment struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec SeldonDeploymentSpec `json:"spec,omitempty"` Status SeldonDeploymentStatus `json:"status,omitempty"` }
+genclient +genclient:noStatus +kubebuilder:object:root=true +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +kubebuilder:storageversion SeldonDeployment is the Schema for the seldondeployments API +k8s:openapi-gen=true +kubebuilder:resource:shortName=sdep +kubebuilder:subresource:status +kubebuilder:subresource:scale:specpath=.spec.replicas,statuspath=.status.replicas
func (*SeldonDeployment) DeepCopy ¶
func (in *SeldonDeployment) DeepCopy() *SeldonDeployment
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SeldonDeployment.
func (*SeldonDeployment) DeepCopyInto ¶
func (in *SeldonDeployment) DeepCopyInto(out *SeldonDeployment)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*SeldonDeployment) DeepCopyObject ¶
func (in *SeldonDeployment) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*SeldonDeployment) Default ¶
func (r *SeldonDeployment) Default()
func (*SeldonDeployment) SetupWebhookWithManager ¶
func (r *SeldonDeployment) SetupWebhookWithManager(mgr ctrl.Manager) error
func (*SeldonDeployment) ValidateCreate ¶
func (r *SeldonDeployment) ValidateCreate() error
ValidateCreate implements webhook.Validator so a webhook will be registered for the type
func (*SeldonDeployment) ValidateDelete ¶
func (r *SeldonDeployment) ValidateDelete() error
ValidateDelete implements webhook.Validator so a webhook will be registered for the type
func (*SeldonDeployment) ValidateUpdate ¶
func (r *SeldonDeployment) ValidateUpdate(old runtime.Object) error
ValidateUpdate implements webhook.Validator so a webhook will be registered for the type
type SeldonDeploymentList ¶
type SeldonDeploymentList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []SeldonDeployment `json:"items"` }
SeldonDeploymentList contains a list of SeldonDeployment
func (*SeldonDeploymentList) DeepCopy ¶
func (in *SeldonDeploymentList) DeepCopy() *SeldonDeploymentList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SeldonDeploymentList.
func (*SeldonDeploymentList) DeepCopyInto ¶
func (in *SeldonDeploymentList) DeepCopyInto(out *SeldonDeploymentList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*SeldonDeploymentList) DeepCopyObject ¶
func (in *SeldonDeploymentList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type SeldonDeploymentSpec ¶
type SeldonDeploymentSpec struct { //Name is Deprecated will be removed in future Name string `json:"name,omitempty" protobuf:"string,1,opt,name=name"` Predictors []PredictorSpec `json:"predictors" protobuf:"bytes,2,opt,name=name"` OauthKey string `json:"oauth_key,omitempty" protobuf:"string,3,opt,name=oauth_key"` OauthSecret string `json:"oauth_secret,omitempty" protobuf:"string,4,opt,name=oauth_secret"` Annotations map[string]string `json:"annotations,omitempty" protobuf:"bytes,5,opt,name=annotations"` Protocol Protocol `json:"protocol,omitempty" protobuf:"bytes,6,opt,name=protocol"` Transport Transport `json:"transport,omitempty" protobuf:"bytes,7,opt,name=transport"` Replicas *int32 `json:"replicas,omitempty" protobuf:"bytes,8,opt,name=replicas"` ServerType ServerType `json:"serverType,omitempty" protobuf:"bytes,9,opt,name=serverType"` }
SeldonDeploymentSpec defines the desired state of SeldonDeployment
func (*SeldonDeploymentSpec) DeepCopy ¶
func (in *SeldonDeploymentSpec) DeepCopy() *SeldonDeploymentSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SeldonDeploymentSpec.
func (*SeldonDeploymentSpec) DeepCopyInto ¶
func (in *SeldonDeploymentSpec) DeepCopyInto(out *SeldonDeploymentSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*SeldonDeploymentSpec) DefaultSeldonDeployment ¶
func (r *SeldonDeploymentSpec) DefaultSeldonDeployment(mldepName string, namespace string)
func (*SeldonDeploymentSpec) ValidateSeldonDeployment ¶
func (r *SeldonDeploymentSpec) ValidateSeldonDeployment() error
type SeldonDeploymentStatus ¶
type SeldonDeploymentStatus struct { State StatusState `json:"state,omitempty" protobuf:"string,1,opt,name=state"` Description string `json:"description,omitempty" protobuf:"string,2,opt,name=description"` DeploymentStatus map[string]DeploymentStatus `json:"deploymentStatus,omitempty" protobuf:"bytes,3,opt,name=deploymentStatus"` ServiceStatus map[string]ServiceStatus `json:"serviceStatus,omitempty" protobuf:"bytes,4,opt,name=serviceStatus"` Replicas int32 `json:"replicas,omitempty" protobuf:"string,5,opt,name=replicas"` Address *SeldonAddressable `json:"address,omitempty"` duckv1.Status `json:",inline"` }
SeldonDeploymentStatus defines the observed state of SeldonDeployment
func (*SeldonDeploymentStatus) CreateCondition ¶ added in v1.11.1
func (ss *SeldonDeploymentStatus) CreateCondition(conditionType apis.ConditionType, isTrue bool, reason string)
func (*SeldonDeploymentStatus) DeepCopy ¶
func (in *SeldonDeploymentStatus) DeepCopy() *SeldonDeploymentStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SeldonDeploymentStatus.
func (*SeldonDeploymentStatus) DeepCopyInto ¶
func (in *SeldonDeploymentStatus) DeepCopyInto(out *SeldonDeploymentStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*SeldonDeploymentStatus) GetCondition ¶ added in v1.11.1
func (ss *SeldonDeploymentStatus) GetCondition(t apis.ConditionType) *apis.Condition
GetCondition returns the condition by name.
func (*SeldonDeploymentStatus) InitializeConditions ¶ added in v1.11.1
func (ss *SeldonDeploymentStatus) InitializeConditions()
func (*SeldonDeploymentStatus) IsConditionReady ¶ added in v1.11.1
func (ss *SeldonDeploymentStatus) IsConditionReady(t apis.ConditionType) bool
IsConditionReady returns the readiness for a given condition
func (*SeldonDeploymentStatus) IsReady ¶ added in v1.11.1
func (ss *SeldonDeploymentStatus) IsReady() bool
IsReady returns if the service is ready to serve the requested configuration.
func (*SeldonDeploymentStatus) SetCondition ¶ added in v1.11.1
func (ss *SeldonDeploymentStatus) SetCondition(conditionType apis.ConditionType, condition *apis.Condition)
type SeldonHpaSpec ¶
type SeldonHpaSpec struct { MinReplicas *int32 `json:"minReplicas,omitempty" protobuf:"int,1,opt,name=minReplicas"` MaxReplicas int32 `json:"maxReplicas" protobuf:"int,2,opt,name=maxReplicas"` Metrics []autoscalingv2beta2.MetricSpec `json:"metrics,omitempty" protobuf:"bytes,3,opt,name=metrics"` }
func (*SeldonHpaSpec) DeepCopy ¶
func (in *SeldonHpaSpec) DeepCopy() *SeldonHpaSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SeldonHpaSpec.
func (*SeldonHpaSpec) DeepCopyInto ¶
func (in *SeldonHpaSpec) DeepCopyInto(out *SeldonHpaSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SeldonPdbSpec ¶
type SeldonPdbSpec struct { // An eviction is allowed if at least "minAvailable" pods in the deployment // corresponding to a componentSpec will still be available after the eviction, i.e. even in the // absence of the evicted pod. So for example you can prevent all voluntary // evictions by specifying "100%". // +optional MinAvailable *intstr.IntOrString `json:"minAvailable,omitempty" protobuf:"bytes,1,opt,name=minAvailable"` // corresponding to a componentSpec are unavailable after the eviction, i.e. even in absence of // the evicted pod. For example, one can prevent all voluntary evictions // by specifying 0. // MaxUnavailable and MinAvailable are mutually exclusive. // +optional MaxUnavailable *intstr.IntOrString `json:"maxUnavailable,omitempty" protobuf:"bytes,2,opt,name=maxUnavailable"` }
func (*SeldonPdbSpec) DeepCopy ¶
func (in *SeldonPdbSpec) DeepCopy() *SeldonPdbSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SeldonPdbSpec.
func (*SeldonPdbSpec) DeepCopyInto ¶
func (in *SeldonPdbSpec) DeepCopyInto(out *SeldonPdbSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SeldonPodSpec ¶
type SeldonPodSpec struct { Metadata ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` Spec v1.PodSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` HpaSpec *SeldonHpaSpec `json:"hpaSpec,omitempty" protobuf:"bytes,3,opt,name=hpaSpec"` Replicas *int32 `json:"replicas,omitempty" protobuf:"bytes,4,opt,name=replicas"` KedaSpec *SeldonScaledObjectSpec `json:"kedaSpec,omitempty" protobuf:"bytes,5,opt,name=kedaSpec"` PdbSpec *SeldonPdbSpec `json:"pdbSpec,omitempty" protobuf:"bytes,6,opt,name=pdbSpec"` }
func (*SeldonPodSpec) DeepCopy ¶
func (in *SeldonPodSpec) DeepCopy() *SeldonPodSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SeldonPodSpec.
func (*SeldonPodSpec) DeepCopyInto ¶
func (in *SeldonPodSpec) DeepCopyInto(out *SeldonPodSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SeldonScaledObjectSpec ¶
type SeldonScaledObjectSpec struct { // +optional PollingInterval *int32 `json:"pollingInterval,omitempty" protobuf:"int,1,opt,name=pollingInterval"` // +optional CooldownPeriod *int32 `json:"cooldownPeriod,omitempty" protobuf:"int,2,opt,name=cooldownPeriod"` // +optional MinReplicaCount *int32 `json:"minReplicaCount,omitempty" protobuf:"int,3,opt,name=minReplicaCount"` // +optional MaxReplicaCount *int32 `json:"maxReplicaCount,omitempty" protobuf:"int,4,opt,name=maxReplicaCount"` // +optional Advanced *kedav1alpha1.AdvancedConfig `json:"advanced,omitempty" protobuf:"bytes,5,opt,name=advanced"` Triggers []kedav1alpha1.ScaleTriggers `json:"triggers" protobuf:"bytes,6,opt,name=triggers"` }
SeldonScaledObjectSpec is the spec for a KEDA ScaledObject resource
func (*SeldonScaledObjectSpec) DeepCopy ¶
func (in *SeldonScaledObjectSpec) DeepCopy() *SeldonScaledObjectSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SeldonScaledObjectSpec.
func (*SeldonScaledObjectSpec) DeepCopyInto ¶
func (in *SeldonScaledObjectSpec) DeepCopyInto(out *SeldonScaledObjectSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ServerType ¶
type ServerType string
const ( ServerRPC ServerType = "rpc" ServerKafka ServerType = "kafka" )
type ServiceStatus ¶
type ServiceStatus struct { SvcName string `json:"svcName,omitempty" protobuf:"string,1,opt,name=svcName"` HttpEndpoint string `json:"httpEndpoint,omitempty" protobuf:"string,2,opt,name=httpEndpoint"` GrpcEndpoint string `json:"grpcEndpoint,omitempty" protobuf:"string,3,opt,name=grpcEndpoint"` ExplainerFor string `json:"explainerFor,omitempty" protobuf:"string,4,opt,name=explainerFor"` }
func (*ServiceStatus) DeepCopy ¶
func (in *ServiceStatus) DeepCopy() *ServiceStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ServiceStatus.
func (*ServiceStatus) DeepCopyInto ¶
func (in *ServiceStatus) DeepCopyInto(out *ServiceStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type StatusState ¶
type StatusState string
const ( StatusStateAvailable StatusState = "Available" StatusStateCreating StatusState = "Creating" StatusStateFailed StatusState = "Failed" )
CRD Status values
type SvcOrchSpec ¶
type SvcOrchSpec struct { Resources *v1.ResourceRequirements `json:"resources,omitempty" protobuf:"bytes,1,opt,name=resources"` Env []*v1.EnvVar `json:"env,omitempty" protobuf:"bytes,2,opt,name=env"` Replicas *int32 `json:"replicas,omitempty" protobuf:"bytes,3,opt,name=replicas"` }
func (*SvcOrchSpec) DeepCopy ¶
func (in *SvcOrchSpec) DeepCopy() *SvcOrchSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SvcOrchSpec.
func (*SvcOrchSpec) DeepCopyInto ¶
func (in *SvcOrchSpec) DeepCopyInto(out *SvcOrchSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.