Пример #1
0
func initSched(c *conf.Conf) (*Schedule, error) {
	c.StateFile = ""
	s := new(Schedule)
	s.DataAccess = db
	err := s.Init(c)
	return s, err
}
Пример #2
0
func initSched(c *conf.Conf) (*Schedule, error) {
	c.StateFile = ""
	s := new(Schedule)
	s.DataAccess = &nopDataAccess{failingAlerts: map[string]bool{}}
	err := s.Init(c)
	return s, err
}
Пример #3
0
func initSched(c *conf.Conf) (*Schedule, error) {
	c.StateFile = ""
	s := new(Schedule)
	s.DataAccess = &nopDataAccess{
		failingAlerts: map[string]bool{},
		incidents:     map[uint64]*models.Incident{},
		silences:      map[string]*models.Silence{},
	}
	err := s.Init(c)
	return s, err
}