This is an automated email from the ASF dual-hosted git repository.
zhongxjian pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/dubbo-kubernetes.git
The following commit(s) were added to refs/heads/master by this push:
new a39c1448 [horus] Add node downtime config (#356)
a39c1448 is described below
commit a39c14483c8336b0691a28f3575a5a38b6967fe2
Author: mfordjody <[email protected]>
AuthorDate: Sat Sep 21 12:12:27 2024 +0800
[horus] Add node downtime config (#356)
---
app/horus/basic/config/file.go | 9 +++++++++
deploy/horus/horus.yaml | 13 ++++++++++++-
2 files changed, 21 insertions(+), 1 deletion(-)
diff --git a/app/horus/basic/config/file.go b/app/horus/basic/config/file.go
index 18ae7e3a..1021cdd1 100644
--- a/app/horus/basic/config/file.go
+++ b/app/horus/basic/config/file.go
@@ -25,6 +25,7 @@ type Config struct {
PromMultiple map[string]string `yaml:"promMultiple"`
NodeRecovery *RecoveryConfiguration `yaml:"nodeRecovery"`
CustomModular *ModularConfiguration `yaml:"customModular"`
+ NodeDownTime *DowntimeConfiguration `yaml:"nodeDownTime"`
}
type MysqlConfiguration struct {
@@ -63,3 +64,11 @@ type ModularConfiguration struct {
DingTalk *DingTalkConfiguration `yaml:"dingTalk"`
Slack *SlackConfiguration `yaml:"slack"`
}
+
+type DowntimeConfiguration struct {
+ Enabled bool `yaml:"enabled"`
+ CheckIntervalSecond int `yaml:"checkIntervalSecond"`
+ PromQueryTimeSecond int64 `yaml:"promQueryTimeSecond"`
+ CheckQL []string `yaml:"checkQL"`
+ DingTalk *DingTalkConfiguration `yaml:"dingTalk"`
+}
diff --git a/deploy/horus/horus.yaml b/deploy/horus/horus.yaml
index 4fb6e780..2d2229fb 100644
--- a/deploy/horus/horus.yaml
+++ b/deploy/horus/horus.yaml
@@ -71,4 +71,15 @@ customModular:
atMobiles:
- 15000000
slack:
- webhookUrl:
"https://hooks.slack.com/services/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"
\ No newline at end of file
+ webhookUrl:
"https://hooks.slack.com/services/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"
+
+nodeDownTime:
+ enabled: false
+ checkIntervalSecond: 5
+ promQueryTimeSecond: 60
+ checkQL:
+ dingTalk:
+ webhookUrl:
"https://oapi.dingtalk.com/robot/send?access_token=37f8891e60e524013275cc01efafdb5976b81ef7269ce271b769bcd025826c12"
+ title: "horus 通知"
+ atMobiles:
+ - 15000000
\ No newline at end of file