Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 0 additions & 26 deletions actions/config/config.go
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
package config

import (
"time"

"github.com/flyteorg/flyte/v2/flytestdlib/config"
)

Expand All @@ -23,31 +21,10 @@ var defaultConfig = &Config{
RunServiceURL: "http://localhost:8090",
// 8M slots × 8 bytes/pointer = 64 MB; can track ~8M unique actions.
RecordFilterSize: 1 << 23,
Apps: AppConfig{
Enabled: false,
Namespace: "flyte-apps",
DefaultRequestTimeout: 5 * time.Minute,
MaxRequestTimeout: time.Hour,
},
}

var configSection = config.MustRegisterSection(configSectionKey, defaultConfig)

// AppConfig holds configuration for the App deployment controller.
type AppConfig struct {
// Enabled controls whether the app deployment controller is started.
Enabled bool `json:"enabled" pflag:",Enable app deployment controller"`

// Namespace is the K8s namespace where KService CRDs are created.
Namespace string `json:"namespace" pflag:",Namespace for app KServices"`

// DefaultRequestTimeout is the request timeout applied to apps that don't specify one.
DefaultRequestTimeout time.Duration `json:"defaultRequestTimeout" pflag:",Default request timeout for apps"`

// MaxRequestTimeout is the hard cap on request timeout (Knative max is 3600s).
MaxRequestTimeout time.Duration `json:"maxRequestTimeout" pflag:",Maximum allowed request timeout for apps"`
}

// Config holds the configuration for the Actions service
type Config struct {
// HTTP server configuration
Expand All @@ -68,9 +45,6 @@ type Config struct {

// RecordFilterSize is the size of the bloom filter used to deduplicate RecordAction calls.
RecordFilterSize int `json:"recordFilterSize" pflag:",Size of the oppo bloom filter for deduplicating RecordAction calls"`

// Apps holds configuration for the app deployment controller.
Apps AppConfig `json:"apps"`
}

// ServerConfig holds HTTP server configuration
Expand Down
15 changes: 15 additions & 0 deletions app/config/config.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
package config

import "time"

// AppConfig holds configuration for the App deployment controller.
type AppConfig struct {
// Enabled controls whether the app deployment controller is started.
Enabled bool `json:"enabled" pflag:",Enable app deployment controller"`

// DefaultRequestTimeout is the request timeout applied to apps that don't specify one.
DefaultRequestTimeout time.Duration `json:"defaultRequestTimeout" pflag:",Default request timeout for apps"`

// MaxRequestTimeout is the hard cap on request timeout (Knative max is 3600s).
MaxRequestTimeout time.Duration `json:"maxRequestTimeout" pflag:",Maximum allowed request timeout for apps"`
}
Loading
Loading