Documentation
¶
Index ¶
- func AddPeer(conf config.Configuration, iam uuid.UUID, ep string)
- func ConfigureAgent(conf config.Configuration, name string, roles []string) (model.AgentConfig, error)
- func DataStats(conf config.Configuration) (map[string]int, error)
- func DeletedCheckCleanup(conf config.Configuration, id uuid.UUID)
- func DeletedSubjectCleanup(conf config.Configuration, id uuid.UUID)
- func FillCheckStateDetails(ctx model.AppContext, states []model.CheckState) ([]model.CheckStateDetail, error)
- func GetPeers(conf config.Configuration) map[string]string
- func Info(conf config.Configuration) model.CoordinatorInfo
- func RecordCheckResult(result model.CheckResult, ctx model.AppContext, conf config.Configuration) error
- func UpdatedCheckCleanup(conf config.Configuration, checkID uuid.UUID, oldRoles, newRoles []string)
- func UpdatedSubjectCleanup(conf config.Configuration, subjectID uuid.UUID, oldRoles, newRoles []string)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddPeer ¶
func AddPeer(conf config.Configuration, iam uuid.UUID, ep string)
AddPeer registers a new peer coordinator.
func ConfigureAgent ¶
func ConfigureAgent(conf config.Configuration, name string, roles []string) (model.AgentConfig, error)
ConfigureAgent builds an agent config, creating the Subject if necessary.
func DataStats ¶
func DataStats(conf config.Configuration) (map[string]int, error)
DataStats returns counts of each entity type.
func DeletedCheckCleanup ¶
func DeletedCheckCleanup(conf config.Configuration, id uuid.UUID)
DeletedCheckCleanup handles removing states & results for a check that's been deleted.
func DeletedSubjectCleanup ¶
func DeletedSubjectCleanup(conf config.Configuration, id uuid.UUID)
DeletedSubjectCleanup handles removing states & results for a subject that's been deleted.
func FillCheckStateDetails ¶
func FillCheckStateDetails(ctx model.AppContext, states []model.CheckState) ([]model.CheckStateDetail, error)
FillCheckStateDetails transforms a collection of CheckStates into CheckStateDetails by looking up the check & subject for each.
func GetPeers ¶
func GetPeers(conf config.Configuration) map[string]string
GetPeers returns all currently known live peers. If an id of the requesting coordinator is provided, it will be added to this node's known peers.
func Info ¶
func Info(conf config.Configuration) model.CoordinatorInfo
Info returns information about the running Coordinator instance.
func RecordCheckResult ¶
func RecordCheckResult(result model.CheckResult, ctx model.AppContext, conf config.Configuration) error
RecordCheckResult including updating check state.
func UpdatedCheckCleanup ¶
func UpdatedCheckCleanup(conf config.Configuration, checkID uuid.UUID, oldRoles, newRoles []string)
UpdatedCheckCleanup handles cleaning up check states and results when a check is modified to no longer apply to some subjects.
func UpdatedSubjectCleanup ¶
func UpdatedSubjectCleanup(conf config.Configuration, subjectID uuid.UUID, oldRoles, newRoles []string)
UpdatedSubjectCleanup handles cleaning up check states and results when a subject is modified to no longer apply to some checks.
Types ¶
This section is empty.