Documentation ¶
Index ¶
- Constants
- Variables
- type JobConfig
- type JobSchedulerConfig
- type Manager
- func (manager *Manager) Close()
- func (manager *Manager) GetDeleteNodesSchedulerConfig() JobConfig
- func (manager *Manager) GetJobConfig(jID int) JobConfig
- func (manager *Manager) GetJobSchedulerConfig() JobSchedulerConfig
- func (manager *Manager) GetJobsID() []int
- func (manager *Manager) GetMissingNodesForDeletionSchedulerConfig() JobConfig
- func (manager *Manager) GetNodesMissingSchedulerConfig() JobConfig
- func (manager *Manager) GetProjectUpdateConfig() project_update_lib.ProjectUpdateConfig
- func (manager *Manager) UpdateDeleteNodesSchedulerConfig(jConfig JobConfig) error
- func (manager *Manager) UpdateJobSchedulerConfig(jobSchedulerConfig JobSchedulerConfig) error
- func (manager *Manager) UpdateMissingNodesForDeletionSchedulerConfig(jConfig JobConfig) error
- func (manager *Manager) UpdateNodesMissingSchedulerConfig(jConfig JobConfig) error
- func (manager *Manager) UpdateProjectUpdateConfig(projectUpdateConfig project_update_lib.ProjectUpdateConfig) error
Constants ¶
const ( DeleteNodes int = iota NodesMissing MissingNodesForDeletion )
Enum jobs
Variables ¶
var JobList = map[int]string{ DeleteNodes: "delete_nodes", NodesMissing: "missing_nodes", MissingNodesForDeletion: "missing_nodes_for_deletion", }
List of jobs
Functions ¶
This section is empty.
Types ¶
type JobConfig ¶
type JobConfig struct { // The ID of the job ID int `toml:"id"` // The threshold time that the job will use internally to do a task Threshold string `toml:"threshold"` // How often to run the job Every string `toml:"every"` // Is the job running Running bool `toml:"running"` }
JobConfig is the config for a job
func (*JobConfig) ApplyJobSettings ¶
func (jc *JobConfig) ApplyJobSettings(settings *ingest.JobSettings) (bool, error)
ApplyJobSettings will apply the provided settings to the job configuration returns 'true' if the configuration was modified to indicate that an update is needed
type JobSchedulerConfig ¶
type JobSchedulerConfig struct { // Is the job scheduler running Running bool `toml:"running"` }
JobSchedulerConfig - the config for the job scheduler
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
Manager - configuration manager for the service
func NewManager ¶
NewManager - create a new config. There should only be one config for the service.
func (*Manager) GetDeleteNodesSchedulerConfig ¶
GetDeleteNodesSchedulerConfig get the delete node config
func (*Manager) GetJobConfig ¶
GetJobConfig returns the configuration of the provided job. if the job doesn't exist, it returns an empty config
func (*Manager) GetJobSchedulerConfig ¶
func (manager *Manager) GetJobSchedulerConfig() JobSchedulerConfig
GetJobSchedulerConfig get the job scheduler config
func (*Manager) GetMissingNodesForDeletionSchedulerConfig ¶
GetMissingNodesForDeletionSchedulerConfig get the node missing config
func (*Manager) GetNodesMissingSchedulerConfig ¶
GetNodesMissingSchedulerConfig get the node missing config
func (*Manager) GetProjectUpdateConfig ¶
func (manager *Manager) GetProjectUpdateConfig() project_update_lib.ProjectUpdateConfig
GetProjectUpdateConfig - get the project update config data
func (*Manager) UpdateDeleteNodesSchedulerConfig ¶
UpdateDeleteNodesSchedulerConfig - update the delete node config
func (*Manager) UpdateJobSchedulerConfig ¶
func (manager *Manager) UpdateJobSchedulerConfig(jobSchedulerConfig JobSchedulerConfig) error
UpdateJobSchedulerConfig - update the job scheduler config
func (*Manager) UpdateMissingNodesForDeletionSchedulerConfig ¶
UpdateMissingNodesForDeletionSchedulerConfig update the missing nodes for deletion config
func (*Manager) UpdateNodesMissingSchedulerConfig ¶
UpdateNodesMissingSchedulerConfig update the missing nodes for deletion task
func (*Manager) UpdateProjectUpdateConfig ¶
func (manager *Manager) UpdateProjectUpdateConfig(projectUpdateConfig project_update_lib.ProjectUpdateConfig) error
UpdateProjectUpdateConfig - update the project update config