From 282b4b35c3c7999efb3b53468764b3b0ee9cf589 Mon Sep 17 00:00:00 2001 From: Udit Samani Date: Tue, 1 Oct 2024 14:09:05 +0100 Subject: [PATCH] delete unused config (#4571) closes #4570 --- pkg/config/types/compute.go | 1 - pkg/config/types/generated_constants.go | 19 -------- pkg/config/types/generated_descriptions.go | 55 +++++++--------------- pkg/config/types/orchestrator.go | 1 - pkg/config/types/storage.go | 10 ---- 5 files changed, 18 insertions(+), 68 deletions(-) diff --git a/pkg/config/types/compute.go b/pkg/config/types/compute.go index 168f576bc1..ca3568e28a 100644 --- a/pkg/config/types/compute.go +++ b/pkg/config/types/compute.go @@ -5,7 +5,6 @@ type Compute struct { Enabled bool `yaml:"Enabled,omitempty"` // Orchestrators specifies a list of orchestrator endpoints that this compute node connects to. Orchestrators []string `yaml:"Orchestrators,omitempty"` - TLS TLS `yaml:"TLS,omitempty"` Heartbeat Heartbeat `yaml:"Heartbeat,omitempty"` // Labels are key-value pairs used to describe and categorize the compute node. Labels map[string]string `yaml:"Labels,omitempty"` diff --git a/pkg/config/types/generated_constants.go b/pkg/config/types/generated_constants.go index dc940d1c00..e98d36df93 100644 --- a/pkg/config/types/generated_constants.go +++ b/pkg/config/types/generated_constants.go @@ -22,14 +22,6 @@ const OrchestratorHostKey = "orchestrator.host" const OrchestratorPortKey = "orchestrator.port" const OrchestratorAdvertiseKey = "orchestrator.advertise" const OrchestratorAuthSecretKey = "orchestrator.authsecret" -const OrchestratorTLSCertFileKey = "orchestrator.tls.certfile" -const OrchestratorTLSKeyFileKey = "orchestrator.tls.keyfile" -const OrchestratorTLSCAFileKey = "orchestrator.tls.cafile" -const OrchestratorTLSUseTLSKey = "orchestrator.tls.usetls" -const OrchestratorTLSInsecureKey = "orchestrator.tls.insecure" -const OrchestratorTLSSelfSignedKey = "orchestrator.tls.selfsigned" -const OrchestratorTLSAutoCertKey = "orchestrator.tls.autocert" -const OrchestratorTLSAutoCertCachePathKey = "orchestrator.tls.autocertcachepath" const OrchestratorClusterNameKey = "orchestrator.cluster.name" const OrchestratorClusterHostKey = "orchestrator.cluster.host" const OrchestratorClusterPortKey = "orchestrator.cluster.port" @@ -44,14 +36,6 @@ const OrchestratorEvaluationBrokerVisibilityTimeoutKey = "orchestrator.evaluatio const OrchestratorEvaluationBrokerMaxRetryCountKey = "orchestrator.evaluationbroker.maxretrycount" const ComputeEnabledKey = "compute.enabled" const ComputeOrchestratorsKey = "compute.orchestrators" -const ComputeTLSCertFileKey = "compute.tls.certfile" -const ComputeTLSKeyFileKey = "compute.tls.keyfile" -const ComputeTLSCAFileKey = "compute.tls.cafile" -const ComputeTLSUseTLSKey = "compute.tls.usetls" -const ComputeTLSInsecureKey = "compute.tls.insecure" -const ComputeTLSSelfSignedKey = "compute.tls.selfsigned" -const ComputeTLSAutoCertKey = "compute.tls.autocert" -const ComputeTLSAutoCertCachePathKey = "compute.tls.autocertcachepath" const ComputeHeartbeatInfoUpdateIntervalKey = "compute.heartbeat.infoupdateinterval" const ComputeHeartbeatResourceUpdateIntervalKey = "compute.heartbeat.resourceupdateinterval" const ComputeHeartbeatIntervalKey = "compute.heartbeat.interval" @@ -67,9 +51,6 @@ const InputSourcesDisabledKey = "inputsources.disabled" const InputSourcesReadTimeoutKey = "inputsources.readtimeout" const InputSourcesMaxRetryCountKey = "inputsources.maxretrycount" const InputSourcesTypesIPFSEndpointKey = "inputsources.types.ipfs.endpoint" -const InputSourcesTypesS3EndpointKey = "inputsources.types.s3.endpoint" -const InputSourcesTypesS3AccessKeyKey = "inputsources.types.s3.accesskey" -const InputSourcesTypesS3SecretKeyKey = "inputsources.types.s3.secretkey" const PublishersDisabledKey = "publishers.disabled" const PublishersTypesIPFSEndpointKey = "publishers.types.ipfs.endpoint" const PublishersTypesS3PreSignedURLDisabledKey = "publishers.types.s3.presignedurldisabled" diff --git a/pkg/config/types/generated_descriptions.go b/pkg/config/types/generated_descriptions.go index 6ed6716adf..acb9744936 100644 --- a/pkg/config/types/generated_descriptions.go +++ b/pkg/config/types/generated_descriptions.go @@ -4,8 +4,8 @@ package types // ConfigDescriptions maps configuration paths to their descriptions var ConfigDescriptions = map[string]string{ - APIHostKey: "Host specifies the hostname or IP address on which the API server listens or the client connects.", - APIPortKey: "Port specifies the port the publisher serves on.", + APIHostKey: "Host specifies the hostname or IP address for cluster communication.", + APIPortKey: "Port specifies the port number for cluster communication.", APITLSCertFileKey: "CertFile specifies the path to the TLS certificate file.", APITLSKeyFileKey: "KeyFile specifies the path to the TLS private key file.", APITLSCAFileKey: "CAFile specifies the path to the Certificate Authority file.", @@ -19,22 +19,14 @@ var ConfigDescriptions = map[string]string{ NameProviderKey: "NameProvider specifies the method used to generate names for the node. One of: hostname, aws, gcp, uuid, puuid.", DataDirKey: "DataDir specifies a location on disk where the bacalhau node will maintain state.", StrictVersionMatchKey: "StrictVersionMatch indicates whether to enforce strict version matching.", - OrchestratorEnabledKey: "Enabled indicates whether the compute node is active and available for job execution.", - OrchestratorHostKey: "Host specifies the hostname or IP address on which the API server listens or the client connects.", - OrchestratorPortKey: "Port specifies the port the publisher serves on.", + OrchestratorEnabledKey: "Enabled indicates whether the orchestrator node is active and available for job submission.", + OrchestratorHostKey: "Host specifies the hostname or IP address for cluster communication.", + OrchestratorPortKey: "Port specifies the port number for cluster communication.", OrchestratorAdvertiseKey: "Advertise specifies the address to advertise to other cluster members.", OrchestratorAuthSecretKey: "AuthSecret key specifies the key used by compute nodes to connect to an orchestrator.", - OrchestratorTLSCertFileKey: "CertFile specifies the path to the TLS certificate file.", - OrchestratorTLSKeyFileKey: "KeyFile specifies the path to the TLS private key file.", - OrchestratorTLSCAFileKey: "CAFile specifies the path to the Certificate Authority file.", - OrchestratorTLSUseTLSKey: "UseTLS indicates whether to use TLS for client connections.", - OrchestratorTLSInsecureKey: "Insecure allows insecure TLS connections (e.g., self-signed certificates).", - OrchestratorTLSSelfSignedKey: "SelfSigned indicates whether to use a self-signed certificate.", - OrchestratorTLSAutoCertKey: "AutoCert specifies the domain for automatic certificate generation.", - OrchestratorTLSAutoCertCachePathKey: "AutoCertCachePath specifies the directory to cache auto-generated certificates.", OrchestratorClusterNameKey: "Name specifies the unique identifier for this orchestrator cluster.", - OrchestratorClusterHostKey: "Host specifies the hostname or IP address on which the API server listens or the client connects.", - OrchestratorClusterPortKey: "Port specifies the port the publisher serves on.", + OrchestratorClusterHostKey: "Host specifies the hostname or IP address for cluster communication.", + OrchestratorClusterPortKey: "Port specifies the port number for cluster communication.", OrchestratorClusterAdvertiseKey: "Advertise specifies the address to advertise to other cluster members.", OrchestratorClusterPeersKey: "Peers is a list of other cluster members to connect to on startup.", OrchestratorNodeManagerDisconnectTimeoutKey: "DisconnectTimeout specifies how long to wait before considering a node disconnected.", @@ -43,47 +35,36 @@ var ConfigDescriptions = map[string]string{ OrchestratorSchedulerHousekeepingIntervalKey: "HousekeepingInterval specifies how often to run housekeeping tasks.", OrchestratorSchedulerHousekeepingTimeoutKey: "HousekeepingTimeout specifies the maximum time allowed for a single housekeeping run.", OrchestratorEvaluationBrokerVisibilityTimeoutKey: "VisibilityTimeout specifies how long an evaluation can be claimed before it's returned to the queue.", - OrchestratorEvaluationBrokerMaxRetryCountKey: "ReadTimeout specifies the maximum number of attempts for reading from a storage.", - ComputeEnabledKey: "Enabled indicates whether the compute node is active and available for job execution.", + OrchestratorEvaluationBrokerMaxRetryCountKey: "MaxRetryCount specifies the maximum number of times an evaluation can be retried before being marked as failed.", + ComputeEnabledKey: "Enabled indicates whether the orchestrator node is active and available for job submission.", ComputeOrchestratorsKey: "Orchestrators specifies a list of orchestrator endpoints that this compute node connects to.", - ComputeTLSCertFileKey: "CertFile specifies the path to the TLS certificate file.", - ComputeTLSKeyFileKey: "KeyFile specifies the path to the TLS private key file.", - ComputeTLSCAFileKey: "CAFile specifies the path to the Certificate Authority file.", - ComputeTLSUseTLSKey: "UseTLS indicates whether to use TLS for client connections.", - ComputeTLSInsecureKey: "Insecure allows insecure TLS connections (e.g., self-signed certificates).", - ComputeTLSSelfSignedKey: "SelfSigned indicates whether to use a self-signed certificate.", - ComputeTLSAutoCertKey: "AutoCert specifies the domain for automatic certificate generation.", - ComputeTLSAutoCertCachePathKey: "AutoCertCachePath specifies the directory to cache auto-generated certificates.", ComputeHeartbeatInfoUpdateIntervalKey: "InfoUpdateInterval specifies the time between updates of non-resource information to the orchestrator.", ComputeHeartbeatResourceUpdateIntervalKey: "ResourceUpdateInterval specifies the time between updates of resource information to the orchestrator.", - ComputeHeartbeatIntervalKey: "Interval specifies the time between heartbeat signals sent to the orchestrator.", + ComputeHeartbeatIntervalKey: "Interval specifies the time between update checks, when set to 0 update checks are not performed.", ComputeLabelsKey: "Labels are key-value pairs used to describe and categorize the compute node.", ComputeAllocatedCapacityCPUKey: "CPU specifies the default amount of CPU allocated to a task. It uses Kubernetes resource string format (e.g., \"100m\" for 0.1 CPU cores). This value is used when the task hasn't explicitly set its CPU requirement.", ComputeAllocatedCapacityMemoryKey: "Memory specifies the default amount of memory allocated to a task. It uses Kubernetes resource string format (e.g., \"256Mi\" for 256 mebibytes). This value is used when the task hasn't explicitly set its memory requirement.", ComputeAllocatedCapacityDiskKey: "Disk specifies the default amount of disk space allocated to a task. It uses Kubernetes resource string format (e.g., \"1Gi\" for 1 gibibyte). This value is used when the task hasn't explicitly set its disk space requirement.", ComputeAllocatedCapacityGPUKey: "GPU specifies the default number of GPUs allocated to a task. It uses Kubernetes resource string format (e.g., \"1\" for 1 GPU). This value is used when the task hasn't explicitly set its GPU requirement.", ComputeAllowListedLocalPathsKey: "AllowListedLocalPaths specifies a list of local file system paths that the compute node is allowed to access.", - WebUIEnabledKey: "Enabled indicates whether the compute node is active and available for job execution.", + WebUIEnabledKey: "Enabled indicates whether the orchestrator node is active and available for job submission.", WebUIListenKey: "Listen specifies the address and port on which the Web UI listens.", - InputSourcesDisabledKey: "Disabled specifies a list of engines that are disabled.", + InputSourcesDisabledKey: "Disabled is a list of downloaders that are disabled.", InputSourcesReadTimeoutKey: "ReadTimeout specifies the maximum time allowed for reading from a storage.", - InputSourcesMaxRetryCountKey: "ReadTimeout specifies the maximum number of attempts for reading from a storage.", + InputSourcesMaxRetryCountKey: "MaxRetryCount specifies the maximum number of times an evaluation can be retried before being marked as failed.", InputSourcesTypesIPFSEndpointKey: "Endpoint specifies the multi-address to connect to for IPFS. e.g /ip4/127.0.0.1/tcp/5001", - InputSourcesTypesS3EndpointKey: "Endpoint specifies the multi-address to connect to for IPFS. e.g /ip4/127.0.0.1/tcp/5001", - InputSourcesTypesS3AccessKeyKey: "AccessKey specifies the access key for the S3 input source.", - InputSourcesTypesS3SecretKeyKey: "SecretKey specifies the secret key for the S3 input source.", - PublishersDisabledKey: "Disabled specifies a list of engines that are disabled.", + PublishersDisabledKey: "Disabled is a list of downloaders that are disabled.", PublishersTypesIPFSEndpointKey: "Endpoint specifies the multi-address to connect to for IPFS. e.g /ip4/127.0.0.1/tcp/5001", PublishersTypesS3PreSignedURLDisabledKey: "PreSignedURLDisabled specifies whether pre-signed URLs are enabled for the S3 provider.", PublishersTypesS3PreSignedURLExpirationKey: "PreSignedURLExpiration specifies the duration before a pre-signed URL expires.", PublishersTypesLocalAddressKey: "Address specifies the endpoint the publisher serves on.", - PublishersTypesLocalPortKey: "Port specifies the port the publisher serves on.", + PublishersTypesLocalPortKey: "Port specifies the port number for cluster communication.", PublishersTypesLocalDirectoryKey: "Directory specifies a path to location on disk where content is served from.", - EnginesDisabledKey: "Disabled specifies a list of engines that are disabled.", + EnginesDisabledKey: "Disabled is a list of downloaders that are disabled.", EnginesTypesDockerManifestCacheSizeKey: "Size specifies the size of the Docker manifest cache.", EnginesTypesDockerManifestCacheTTLKey: "TTL specifies the time-to-live duration for cache entries.", EnginesTypesDockerManifestCacheRefreshKey: "Refresh specifies the refresh interval for cache entries.", - ResultDownloadersDisabledKey: "Disabled specifies a list of engines that are disabled.", + ResultDownloadersDisabledKey: "Disabled is a list of downloaders that are disabled.", ResultDownloadersTimeoutKey: "Timeout specifies the maximum time allowed for a download operation.", ResultDownloadersTypesIPFSEndpointKey: "Endpoint specifies the multi-address to connect to for IPFS. e.g /ip4/127.0.0.1/tcp/5001", JobDefaultsBatchPriorityKey: "Priority specifies the default priority allocated to a service or daemon job. This value is used when the job hasn't explicitly set its priority requirement.", @@ -121,7 +102,7 @@ var ConfigDescriptions = map[string]string{ LoggingLevelKey: "Level sets the logging level. One of: trace, debug, info, warn, error, fatal, panic.", LoggingModeKey: "Mode specifies the logging mode. One of: default, json.", LoggingLogDebugInfoIntervalKey: "LogDebugInfoInterval specifies the interval for logging debug information.", - UpdateConfigIntervalKey: "Interval specifies the time between heartbeat signals sent to the orchestrator.", + UpdateConfigIntervalKey: "Interval specifies the time between update checks, when set to 0 update checks are not performed.", FeatureFlagsExecTranslationKey: "ExecTranslation enables the execution translation feature.", DisableAnalyticsKey: "No description available", } diff --git a/pkg/config/types/orchestrator.go b/pkg/config/types/orchestrator.go index 39a1c751b6..5e0a7a6fd3 100644 --- a/pkg/config/types/orchestrator.go +++ b/pkg/config/types/orchestrator.go @@ -11,7 +11,6 @@ type Orchestrator struct { Advertise string `yaml:"Advertise,omitempty"` // AuthSecret key specifies the key used by compute nodes to connect to an orchestrator. AuthSecret string `yaml:"AuthSecret,omitempty"` - TLS TLS `yaml:"TLS,omitempty"` Cluster Cluster `yaml:"Cluster,omitempty"` NodeManager NodeManager `yaml:"NodeManager,omitempty"` Scheduler Scheduler `yaml:"Scheduler,omitempty"` diff --git a/pkg/config/types/storage.go b/pkg/config/types/storage.go index 355dd6f629..bd58e83335 100644 --- a/pkg/config/types/storage.go +++ b/pkg/config/types/storage.go @@ -19,7 +19,6 @@ type InputSourcesConfig struct { type InputSourcesTypes struct { IPFS IPFSStorage `yaml:"IPFS,omitempty"` - S3 S3Storage `yaml:"S3,omitempty"` } func (i InputSourcesConfig) IsNotDisabled(kind string) bool { @@ -32,12 +31,3 @@ type IPFSStorage struct { // Endpoint specifies the multi-address to connect to for IPFS. e.g /ip4/127.0.0.1/tcp/5001 Endpoint string `yaml:"Endpoint,omitempty"` } - -type S3Storage struct { - // Endpoint specifies the endpoint URL for the S3 input source. - Endpoint string `yaml:"Endpoint,omitempty"` - // AccessKey specifies the access key for the S3 input source. - AccessKey string `yaml:"AccessKey,omitempty"` - // SecretKey specifies the secret key for the S3 input source. - SecretKey string `yaml:"SecretKey,omitempty"` -}