-
Notifications
You must be signed in to change notification settings - Fork 32
/
Copy pathconfig.go
34 lines (31 loc) · 1.15 KB
/
config.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
package cluster
import "time"
type Config struct {
InventoryResourcePollPeriod time.Duration
InventoryResourceDebugFrequency uint
InventoryExternalPortQuantity uint
CPUCommitLevel float64
GPUCommitLevel float64
MemoryCommitLevel float64
StorageCommitLevel float64
BlockedHostnames []string
DeploymentIngressStaticHosts bool
DeploymentIngressDomain string
MonitorMaxRetries uint
MonitorRetryPeriod time.Duration
MonitorRetryPeriodJitter time.Duration
MonitorHealthcheckPeriod time.Duration
MonitorHealthcheckPeriodJitter time.Duration
ClusterSettings map[interface{}]interface{}
}
func NewDefaultConfig() Config {
return Config{
InventoryResourcePollPeriod: time.Second * 5,
InventoryResourceDebugFrequency: 10,
MonitorMaxRetries: 40,
MonitorRetryPeriod: time.Second * 4, // nolint revive
MonitorRetryPeriodJitter: time.Second * 15,
MonitorHealthcheckPeriod: time.Second * 10, // nolint revive
MonitorHealthcheckPeriodJitter: time.Second * 5,
}
}