Documentation ¶
Index ¶
- Constants
- Variables
- func DefaultInferenceLoggerName(prefix string) string
- func DefaultKafkaTopicName(modelName string) string
- func DefaultMonitoringJobName(modelName string) string
- func DefaultRoleBindingName(assignee string) string
- func DefaultRoleName(assignee string) string
- func DefaultServiceAccountName(assignee string) string
- type ModelMonitorComponent
Constants ¶
View Source
const ( InferenceLoggerNameSuffix = "inferencelogger" // Labels InferenceLoggerModelLabel = "model" InferenceLoggerEnvKafkaBrokersLabel = "KAFKA_BROKERS" InferenceLoggerEnvKafkaTopicLabel = "KAFKA_TOPIC" InferenceLoggerEnvKafkaTopicPartitionsLabel = "KAFKA_TOPIC_PARTITIONS" InferenceLoggerEnvKafkaTopicReplicationFactorLabel = "KAFKA_TOPIC_REPLICATION_FACTOR" )
InferenceLogger constants
View Source
const ( MonitoringJobNameSuffix = "monitoring-job" // Labels MonitoringJobSparkVersionLabel = "version" MonitoringJobEnvVarModelInfoLabel = "MODEL_INFO" MonitoringJobEnvVarMonitoringConfigLabel = "MONITORING_CONFIG" MonitoringJobEnvVarStorageConfigLabel = "STORAGE_CONFIG" MonitoringJobEnvVarJobConfigLabel = "JOB_CONFIG" )
Job constants
View Source
const ( KafkaTopicNameSuffix = "inference-topic" // Labels KafkaTopicLabel = "topic" KafkaBrokersLabel = "brokers" KafkaTopicPartitionsLabel = "partitions" KafkaTopicReplicationFactorLabel = "replicationFactor" )
KafkaTopic constants
View Source
const ( ServiceAccount = "ServiceAccount" Role = "Role" // Suffix ServiceAccountNameSuffix = "sa" RoleNameSuffix = "r" RoleBindingNameSuffix = "rb" )
Permissions
Variables ¶
View Source
var ( ModelMonitoringName = "model-monitoring" ModelMonitoringAPIGroupName = "monitoring.model.dev" ModelMonitoringNamespace = ModelMonitoringName + "-system" )
ModelMonitoring Operator constants
View Source
var ( ModelMonitorName = "modelmonitor" ModelMonitorAPIName = "modelmonitors" ModelMonitorPodLabelKey = ModelMonitoringAPIGroupName + "/" + ModelMonitorName ModelMonitorConfigMapName = ModelMonitoringName + "-" + ModelMonitorName + "-config" ModelMonitorContainerName = ModelMonitorName + "-container" )
ModelMonitor constants
View Source
var ( ModelMonitorControllerName = ModelMonitorName + "-controller" ControllerLabelName = ModelMonitorControllerName + "-manager" )
ModelMonitor Controller Constants
View Source
var ( InferenceLoggerDefaultCPU = "0.1" InferenceLoggerDefaultMemory = "128Mi" InferenceLoggerDefaultTimeout int64 = 300 InferenceLoggerDefaultScalingClass = autoscaling.KPA // kpa or hpa InferenceLoggerDefaultScalingMetric = "concurrency" // concurrency, rps or cpu (hpa required) InferenceLoggerDefaultScalingTarget = 100 InferenceLoggerDefaultTargetUtilizationPercentage = "70" InferenceLoggerDefaultMinScale = 1 // 0 if scale-to-zero is desired InferenceLoggerDefaultMaxScale = 0 // 0 means limitless InferenceLoggerDefaultWindow = "60s" InferenceLoggerDefaultPanicWindow = "10" // percentage of StableWindow InferenceLoggerDefaultPanicThreshold = "200" )
InferenceLogger defaults
View Source
var ( // Permissions MonitoringJobAssignee = "spark" // Spark MonitoringJobSparkVersion = "2.4.5" MonitoringJobImagePullPolicy = "Always" // Driver MonitoringJobDriverCores int32 = 1 MonitoringJobDriverCoreLimit = "1000m" MonitoringJobDriverMemory = "512m" // Executor MonitoringJobExecutorCores int32 = 1 MonitoringJobExecutorCoreLimit = "1000m" MonitoringJobExecutorMemory = "512m" MonitoringJobExecutorInstances int32 = 1 // Volume MonitoringJobVolumeName = "test-volume" MonitoringJobVolumeHostPath = "/tmp" MonitoringJobVolumeHostPathType = corev1.HostPathDirectory // VolumeMount MonitoringJobVolumeMountName = "test-volume" MonitoringJobVolumeMountPath = "/tmp" // Monitoring MonitoringJobPrometheusExportDriverMetrics = true MonitoringJobPrometheusExportExecutorMetrics = true MonitoringJobPrometheusJmxExporterJar = "/prometheus/jmx_prometheus_javaagent-0.11.0.jar" MonitoringJobPrometheusPort int32 = 8090 )
TODO: Add Driver and Executor variables to api Job template & defaults
Functions ¶
func DefaultInferenceLoggerName ¶
DefaultInferenceLoggerName builds a default name
func DefaultKafkaTopicName ¶
DefaultKafkaTopicName build a default Kafka Topic name
func DefaultMonitoringJobName ¶
DefaultMonitoringJobName build a default Kafka Topic name
func DefaultRoleBindingName ¶
DefaultRoleBindingName build a default Role Binding name
func DefaultRoleName ¶
DefaultRoleName build a default Role name
func DefaultServiceAccountName ¶
DefaultServiceAccountName build a default Service Account name
Types ¶
type ModelMonitorComponent ¶
type ModelMonitorComponent string
ModelMonitorComponent enum
const ( Job ModelMonitorComponent = "job" InferenceLogger ModelMonitorComponent = "inferenceLogger" )
ModelMonitor fields
func (ModelMonitorComponent) String ¶
func (c ModelMonitorComponent) String() string
String return ModelMonitorComponent as string
Click to show internal directories.
Click to hide internal directories.