diff options
Diffstat (limited to 'internal/config/helpers.gen.go')
-rw-r--r-- | internal/config/helpers.gen.go | 75 |
1 files changed, 75 insertions, 0 deletions
diff --git a/internal/config/helpers.gen.go b/internal/config/helpers.gen.go index 415035bea..6e9b71812 100644 --- a/internal/config/helpers.gen.go +++ b/internal/config/helpers.gen.go @@ -3099,6 +3099,81 @@ func GetCacheNotificationMemRatio() float64 { return global.GetCacheNotification // SetCacheNotificationMemRatio safely sets the value for global configuration 'Cache.NotificationMemRatio' field func SetCacheNotificationMemRatio(v float64) { global.SetCacheNotificationMemRatio(v) } +// GetCachePollMemRatio safely fetches the Configuration value for state's 'Cache.PollMemRatio' field +func (st *ConfigState) GetCachePollMemRatio() (v float64) { + st.mutex.RLock() + v = st.config.Cache.PollMemRatio + st.mutex.RUnlock() + return +} + +// SetCachePollMemRatio safely sets the Configuration value for state's 'Cache.PollMemRatio' field +func (st *ConfigState) SetCachePollMemRatio(v float64) { + st.mutex.Lock() + defer st.mutex.Unlock() + st.config.Cache.PollMemRatio = v + st.reloadToViper() +} + +// CachePollMemRatioFlag returns the flag name for the 'Cache.PollMemRatio' field +func CachePollMemRatioFlag() string { return "cache-poll-mem-ratio" } + +// GetCachePollMemRatio safely fetches the value for global configuration 'Cache.PollMemRatio' field +func GetCachePollMemRatio() float64 { return global.GetCachePollMemRatio() } + +// SetCachePollMemRatio safely sets the value for global configuration 'Cache.PollMemRatio' field +func SetCachePollMemRatio(v float64) { global.SetCachePollMemRatio(v) } + +// GetCachePollVoteMemRatio safely fetches the Configuration value for state's 'Cache.PollVoteMemRatio' field +func (st *ConfigState) GetCachePollVoteMemRatio() (v float64) { + st.mutex.RLock() + v = st.config.Cache.PollVoteMemRatio + st.mutex.RUnlock() + return +} + +// SetCachePollVoteMemRatio safely sets the Configuration value for state's 'Cache.PollVoteMemRatio' field +func (st *ConfigState) SetCachePollVoteMemRatio(v float64) { + st.mutex.Lock() + defer st.mutex.Unlock() + st.config.Cache.PollVoteMemRatio = v + st.reloadToViper() +} + +// CachePollVoteMemRatioFlag returns the flag name for the 'Cache.PollVoteMemRatio' field +func CachePollVoteMemRatioFlag() string { return "cache-poll-vote-mem-ratio" } + +// GetCachePollVoteMemRatio safely fetches the value for global configuration 'Cache.PollVoteMemRatio' field +func GetCachePollVoteMemRatio() float64 { return global.GetCachePollVoteMemRatio() } + +// SetCachePollVoteMemRatio safely sets the value for global configuration 'Cache.PollVoteMemRatio' field +func SetCachePollVoteMemRatio(v float64) { global.SetCachePollVoteMemRatio(v) } + +// GetCachePollVoteIDsMemRatio safely fetches the Configuration value for state's 'Cache.PollVoteIDsMemRatio' field +func (st *ConfigState) GetCachePollVoteIDsMemRatio() (v float64) { + st.mutex.RLock() + v = st.config.Cache.PollVoteIDsMemRatio + st.mutex.RUnlock() + return +} + +// SetCachePollVoteIDsMemRatio safely sets the Configuration value for state's 'Cache.PollVoteIDsMemRatio' field +func (st *ConfigState) SetCachePollVoteIDsMemRatio(v float64) { + st.mutex.Lock() + defer st.mutex.Unlock() + st.config.Cache.PollVoteIDsMemRatio = v + st.reloadToViper() +} + +// CachePollVoteIDsMemRatioFlag returns the flag name for the 'Cache.PollVoteIDsMemRatio' field +func CachePollVoteIDsMemRatioFlag() string { return "cache-poll-vote-ids-mem-ratio" } + +// GetCachePollVoteIDsMemRatio safely fetches the value for global configuration 'Cache.PollVoteIDsMemRatio' field +func GetCachePollVoteIDsMemRatio() float64 { return global.GetCachePollVoteIDsMemRatio() } + +// SetCachePollVoteIDsMemRatio safely sets the value for global configuration 'Cache.PollVoteIDsMemRatio' field +func SetCachePollVoteIDsMemRatio(v float64) { global.SetCachePollVoteIDsMemRatio(v) } + // GetCacheReportMemRatio safely fetches the Configuration value for state's 'Cache.ReportMemRatio' field func (st *ConfigState) GetCacheReportMemRatio() (v float64) { st.mutex.RLock() |