-
Notifications
You must be signed in to change notification settings - Fork 69
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(notifier): add selfstate monitor #1118
base: feat/add-selfstate-heartbeats
Are you sure you want to change the base?
feat(notifier): add selfstate monitor #1118
Conversation
cmd/notifier/main.go
Outdated
|
||
// Start moira selfstate checker | ||
if selfstateCfg.Enabled { | ||
fmt.Println(selfstateCfg) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fmt.Println(selfstateCfg) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
поправил, спасибо
LastCheckDelay: "60s", | ||
NoticeInterval: "300s", | ||
Selfstate: selfstateConfig{ | ||
Enabled: false, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
А нужно ли заполнять остальной конфиг, если он по умолчанию выключен? Или типа на случай, если включал и чего-то не заполнят?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Просто оставил старые значения, могу убрать
type AdminMonitorConfig struct { | ||
MonitorBaseConfig | ||
|
||
AdminContacts []map[string]string `validate:"required_if=Enabled true"` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
А почему map[string]string
, структуру нельзя сделать?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Перенес старый вариант, менять на структуру сейчас?
Add selfstate monitor