Browse Source

[Docs] enhance alert doc (#9534)

Co-authored-by: Jiajie Zhong <zhongjiajie955@gmail.com>
3.0.0/version-upgrade
wangyang 3 years ago committed by GitHub
parent
commit
6155dc3dab
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 28
      docs/docs/en/development/backend/spi/alert.md
  2. 6
      docs/docs/en/guide/alert/alert_plugin_user_guide.md
  3. 24
      docs/docs/zh/development/backend/spi/alert.md
  4. 6
      docs/docs/zh/guide/alert/alert_plugin_user_guide.md
  5. BIN
      docs/img/alert/alert_scenarios_en.png
  6. BIN
      docs/img/alert/alert_scenarios_zh.png
  7. BIN
      docs/img/alert/alert_step_2.png
  8. BIN
      docs/img/alert/alert_step_3.png
  9. BIN
      docs/img/alert/alert_step_4.png

28
docs/docs/en/development/backend/spi/alert.md

@ -22,7 +22,7 @@ If you don't care about its internal design, but simply want to know how to deve
* dolphinscheduler-alert-plugins * dolphinscheduler-alert-plugins
This module is currently a plug-in provided by us, such as Email, DingTalk, Script, etc. This module is currently a plug-in provided by us, and now we have supported dozens of plug-ins, such as Email, DingTalk, Script, etc.
#### Alert SPI Main class information. #### Alert SPI Main class information.
@ -60,6 +60,8 @@ The specific design of alert_spi can be seen in the issue: [Alert Plugin Design]
Alert for DingTalk group chat bots Alert for DingTalk group chat bots
Related parameter configuration can refer to the DingTalk robot document.
* EnterpriseWeChat * EnterpriseWeChat
EnterpriseWeChat alert notifications EnterpriseWeChat alert notifications
@ -73,3 +75,27 @@ The specific design of alert_spi can be seen in the issue: [Alert Plugin Design]
* SMS * SMS
SMS alerts SMS alerts
* FeiShu
FeiShu alert notification
* Slack
Slack alert notification
* PagerDuty
PagerDuty alert notification
* WebexTeams
WebexTeams alert notification
Related parameter configuration can refer to the WebexTeams document.
* Telegram
Telegram alert notification
Related parameter configuration can refer to the Telegram document.
* Http
We have implemented a Http script for alerting. And calling most of the alerting plug-ins end up being Http requests, if we not support your alert plug-in yet, you can use Http to realize your alert login. Also welcome to contribute your common plug-ins to the community :)

6
docs/docs/en/guide/alert/alert_plugin_user_guide.md

@ -2,7 +2,11 @@
## How to Create Alert Plugins and Alert Groups ## How to Create Alert Plugins and Alert Groups
In version 2.0.0, users need to create alert instances, and then associate them with alert groups. Alert group can use multiple alert instances and notify them one by one. In version 2.0.0, users need to create alert instances, and needs to choose an alarm policy when defining an alarm instance, there are three options: send if the task succeeds, send on failure, and send on both success and failure. when the workflow or task is executed, if an alarm is triggered, calling the alarm instance send method needs a logical judgment, which matches the alarm instance with the task status, executes the alarm instance sending logic if it matches, and filters if it does not match. When create alert instances then associate them with alert groups. Alert group can use multiple alert instances.
The alarm module supports the following scenarios:
<img src="/img/alert/alert_scenarios_en.png">
The steps to use are as follows:
First, go to the Security Center page. Select Alarm Group Management, click Alarm Instance Management on the left and create an alarm instance. Select the corresponding alarm plug-in and fill in the relevant alarm parameters. First, go to the Security Center page. Select Alarm Group Management, click Alarm Instance Management on the left and create an alarm instance. Select the corresponding alarm plug-in and fill in the relevant alarm parameters.

24
docs/docs/zh/development/backend/spi/alert.md

@ -22,7 +22,7 @@ DolphinScheduler 正在处于微内核 + 插件化的架构更改之中,所有
* dolphinscheduler-alert-plugins * dolphinscheduler-alert-plugins
该模块是目前我们提供的插件,如 Email、DingTalk、Script等。 该模块是目前我们提供的插件,目前我们已经支持数十种插件,如 Email、DingTalk、Script等。
#### Alert SPI 主要类信息: #### Alert SPI 主要类信息:
@ -61,6 +61,7 @@ alert_spi 具体设计可见 issue:[Alert Plugin Design](https://github.com/ap
钉钉群聊机器人告警 钉钉群聊机器人告警
相关参数配置可以参考钉钉机器人文档。
* EnterpriseWeChat * EnterpriseWeChat
企业微信告警通知 企业微信告警通知
@ -69,3 +70,24 @@ alert_spi 具体设计可见 issue:[Alert Plugin Design](https://github.com/ap
* Script * Script
我们实现了 Shell 脚本告警,我们会将相关告警参数透传给脚本,你可以在 Shell 中实现你的相关告警逻辑,如果你需要对接内部告警应用,这是一种不错的方法。 我们实现了 Shell 脚本告警,我们会将相关告警参数透传给脚本,你可以在 Shell 中实现你的相关告警逻辑,如果你需要对接内部告警应用,这是一种不错的方法。
* FeiShu
飞书告警通知
* Slack
Slack告警通知
* PagerDuty
PagerDuty告警通知
* WebexTeams
WebexTeams告警通知
相关参数配置可以参考WebexTeams文档。
* Telegram
Telegram告警通知
相关参数配置可以参考Telegram文档。
* Http
我们实现了Http告警,调用大部分的告警插件最终都是Http请求,如果我们没有支持你常用插件,可以使用Http来实现你的告警需求,同时也欢迎将你常用插件贡献到社区。

6
docs/docs/zh/guide/alert/alert_plugin_user_guide.md

@ -1,6 +1,10 @@
## 如何创建告警插件以及告警组 ## 如何创建告警插件以及告警组
在2.0.0版本中,用户需要创建告警实例,然后同告警组进行关联,一个告警组可以使用多个告警实例,我们会逐一进行进行告警通知。 在2.0.0版本中,用户需要创建告警实例,在创建告警实例时,需要选择告警策略,有三个选项,成功发、失败发,以及成功和失败都发。在执行完工作流或任务时,如果触发告警,调用告警实例发送方法会进行逻辑判断,将告警实例与任务状态进行匹配,匹配则执行该告警实例发送逻辑,不匹配则过滤。创建完告警实例后,需要同告警组进行关联,一个告警组可以使用多个告警实例。
告警模块支持场景如下:
<img src="/img/alert/alert_scenarios_zh.png">
使用步骤如下:
首先需要进入到安全中心,选择告警组管理,然后点击左侧的告警实例管理,然后创建一个告警实例,然后选择对应的告警插件,填写相关告警参数。 首先需要进入到安全中心,选择告警组管理,然后点击左侧的告警实例管理,然后创建一个告警实例,然后选择对应的告警插件,填写相关告警参数。

BIN
docs/img/alert/alert_scenarios_en.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 33 KiB

BIN
docs/img/alert/alert_scenarios_zh.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

BIN
docs/img/alert/alert_step_2.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 34 KiB

After

Width:  |  Height:  |  Size: 155 KiB

BIN
docs/img/alert/alert_step_3.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 43 KiB

After

Width:  |  Height:  |  Size: 234 KiB

BIN
docs/img/alert/alert_step_4.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 77 KiB

After

Width:  |  Height:  |  Size: 141 KiB

Loading…
Cancel
Save