Documentation ¶
Overview ¶
Package housekeeping is the package for housekeeping service. It cleans up the resources and data that is no longer needed.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { // Interval is the time between housekeeping runs. Interval string `yaml:"Interval"` // CandidatesLimitPerProject is the maximum number of candidates to be returned per project. CandidatesLimitPerProject int `yaml:"CandidatesLimitPerProject"` // ProjectFetchSize is the maximum number of projects to be returned to deactivate candidates. ProjectFetchSize int `yaml:"HousekeepingProjectFetchSize"` }
Config is the configuration for the housekeeping service.
func (*Config) ParseInterval ¶ added in v0.4.28
ParseInterval parses the interval.
type Housekeeping ¶
type Housekeeping struct { Config *Config // contains filtered or unexported fields }
Housekeeping is the housekeeping service. It periodically runs housekeeping tasks.
func (*Housekeeping) RegisterTask ¶ added in v0.4.28
func (h *Housekeeping) RegisterTask( interval time.Duration, task func(ctx context.Context) error, ) error
RegisterTask registers task the housekeeping service.
func (*Housekeeping) Start ¶
func (h *Housekeeping) Start() error
Start starts the housekeeping service.
func (*Housekeeping) Stop ¶
func (h *Housekeeping) Stop() error
Stop stops the housekeeping service.
Click to show internal directories.
Click to hide internal directories.