Skip to content

[Feature-3754][Alert] Alert module support service for other service invoke#3979

Merged
CalvinKirs merged 10 commits intoapache:alert_plugin_designfrom
zhuangchong:alert_spi_support_sync_service
Nov 5, 2020
Merged

[Feature-3754][Alert] Alert module support service for other service invoke#3979
CalvinKirs merged 10 commits intoapache:alert_plugin_designfrom
zhuangchong:alert_spi_support_sync_service

Conversation

@zhuangchong
Copy link
Copy Markdown
Contributor

#3754

What is the purpose of the pull request

In this feature , Alert server is a message notification service , email and wechat is a plugin of this service . If you want send email message you can create an instance of email plugin in the alert group and then you can select the alert group in SqlTask . SqlTask can call the alert server api with this alert group arrguement to send the message.

So we need alert api to support other service invoke.

Now the alert service sends alarms abnormally by periodically scanning the records in table t_ds_alert. It is asynchronous.

In the SqlTask task case, the task need send message synchronous and the final running status of this task depends on whether the message is sent successfully. So the alert api need send messages synchronously.

the params of alert api :

  • alert group id : requied, One or more alert plugin instances are associated with an alert group, and these alert plugin instances will be called in turn when sending a message.
  • title : requied, the title of this alert message.
  • content: requied, the content of this alert message.

@zhuangchong zhuangchong changed the title [Feature-3754][Alert] Alert module support service for other service invokeAlert spi support sync service [Feature-3754][Alert] Alert module support service for other service invoke Oct 23, 2020
@codecov-io
Copy link
Copy Markdown

codecov-io commented Oct 24, 2020

Codecov Report

❗ No coverage uploaded for pull request base (alert_plugin_design@20bc747). Click here to learn what that means.
The diff coverage is n/a.

Impacted file tree graph

@@                  Coverage Diff                   @@
##             alert_plugin_design    #3979   +/-   ##
======================================================
  Coverage                       ?   40.73%           
  Complexity                     ?     3011           
======================================================
  Files                          ?      490           
  Lines                          ?    22426           
  Branches                       ?     2664           
======================================================
  Hits                           ?     9136           
  Misses                         ?    12459           
  Partials                       ?      831           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 20bc747...72942ac. Read the comment docs.

@sonarqubecloud
Copy link
Copy Markdown

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities (and Security Hotspot 0 Security Hotspots to review)
Code Smell A 1 Code Smell

36.0% 36.0% Coverage
0.0% 0.0% Duplication

Copy link
Copy Markdown
Member

@EricJoy2048 EricJoy2048 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1

@EricJoy2048 EricJoy2048 force-pushed the alert_plugin_design branch 2 times, most recently from a9a49db to 449cbbe Compare November 3, 2020 08:20
Copy link
Copy Markdown
Member

@CalvinKirs CalvinKirs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1

@CalvinKirs CalvinKirs merged commit c61e536 into apache:alert_plugin_design Nov 5, 2020
@zhuangchong zhuangchong deleted the alert_spi_support_sync_service branch November 5, 2020 12:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants