global limits for reserved shares and unique names (#632)

This commit is contained in:
Michael Quigley 2024-05-21 14:57:14 -04:00
parent fc403a6c22
commit 7d18bea46c
No known key found for this signature in database
GPG Key ID: 9B60314A9DD20A62

View File

@ -5,11 +5,13 @@ import "time"
const Unlimited = -1
type Config struct {
Environments int
Shares int
Bandwidth *BandwidthConfig
Cycle time.Duration
Enforcing bool
Environments int
Shares int
ReservedShares int
UniqueNames int
Bandwidth *BandwidthConfig
Cycle time.Duration
Enforcing bool
}
type BandwidthConfig struct {
@ -48,8 +50,10 @@ func DefaultBandwidthPerPeriod() *BandwidthPerPeriod {
func DefaultConfig() *Config {
return &Config{
Environments: Unlimited,
Shares: Unlimited,
Environments: Unlimited,
Shares: Unlimited,
ReservedShares: Unlimited,
UniqueNames: Unlimited,
Bandwidth: &BandwidthConfig{
PerAccount: DefaultBandwidthPerPeriod(),
PerEnvironment: DefaultBandwidthPerPeriod(),