Skip to content

Commit

Permalink
bugfix threshold init error in mysql env (#1435)
Browse files Browse the repository at this point in the history
Signed-off-by: tomsun28 <[email protected]>
  • Loading branch information
tomsun28 authored Dec 21, 2023
1 parent 13badf3 commit 36c40fc
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 7 deletions.
7 changes: 5 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,13 @@

> An open-source, real-time monitoring system with custom-monitoring, performance-cluster, prometheus-compatible and agentless. | 易用友好的开源实时监控告警系统,无需Agent,高性能集群,兼容Prometheus,强大自定义监控能力.
[![discord](https://img.shields.io/badge/Chat-On%20Discord-brightgreen)](https://discord.gg/Fb6M73htGr)
[<img alt="discord" src="https://img.shields.io/badge/Chat-On%20Discord-brightgreen" height="25"/>](https://discord.gg/Fb6M73htGr)
[<img alt="reddit" src="https://img.shields.io/badge/Reddit-%20Community-brightgreen" height="25"/>](https://www.reddit.com/r/hertzbeat/)
[![Twitter](https://img.shields.io/twitter/follow/hertzbeat1024?logo=twitter)](https://twitter.com/hertzbeat1024)
[![OpenSSF Best Practices](https://www.bestpractices.dev/projects/8139/badge)](https://www.bestpractices.dev/projects/8139)
[![Docker Pulls](https://img.shields.io/docker/pulls/tancloud/hertzbeat?style=%20for-the-badge&logo=docker&label=DockerHub%20Download)](https://hub.docker.com/repository/docker/tancloud/hertzbeat/general)
[![Artifact Hub](https://img.shields.io/endpoint?url=https://artifacthub.io/badge/repository/hertzbeat)](https://artifacthub.io/packages/search?repo=hertzbeat)
[![QQ](https://img.shields.io/badge/qq-236915833-orange)](https://jq.qq.com/?_wv=1027&k=aVIVB2K9)
[![QQ](https://img.shields.io/badge/QQ-236915833-orange)](https://jq.qq.com/?_wv=1027&k=aVIVB2K9)
[![YouTube Channel Subscribers](https://img.shields.io/youtube/channel/subscribers/UCri75zfWX0GHqJFPENEbLow?logo=youtube&label=YouTube%20Channel)](https://www.youtube.com/channel/UCri75zfWX0GHqJFPENEbLow)

**Home: [hertzbeat.dromara.org](https://hertzbeat.dromara.org) Global | [hertzbeat.com](https://hertzbeat.com) China**
Expand Down Expand Up @@ -409,6 +410,8 @@ HertzBeat is a top project under the [Dromara Open Source Community](https://dro

[Github Discussion](https://github.com/dromara/hertzbeat/discussions)

[Reddit Community](https://www.reddit.com/r/hertzbeat/)

[User Club](https://support.qq.com/products/379369)

[Follow Us Twitter](https://twitter.com/hertzbeat1024)
Expand Down
5 changes: 4 additions & 1 deletion README_CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@

> 易用友好的开源实时监控告警系统,无需Agent,高性能集群,兼容Prometheus,强大自定义监控能力。
[![discord](https://img.shields.io/badge/Chat-On%20Discord-brightgreen)](https://discord.gg/Fb6M73htGr)
[<img alt="discord" src="https://img.shields.io/badge/Chat-On%20Discord-brightgreen" height="25"/>](https://discord.gg/Fb6M73htGr)
[<img alt="reddit" src="https://img.shields.io/badge/Reddit-%20Community-brightgreen" height="25"/>](https://www.reddit.com/r/hertzbeat/)
[![Twitter](https://img.shields.io/twitter/follow/hertzbeat1024?logo=twitter)](https://twitter.com/hertzbeat1024)
[![OpenSSF Best Practices](https://www.bestpractices.dev/projects/8139/badge)](https://www.bestpractices.dev/projects/8139)
[![Docker Pulls](https://img.shields.io/docker/pulls/tancloud/hertzbeat?style=%20for-the-badge&logo=docker&label=DockerHub%20Download)](https://hub.docker.com/repository/docker/tancloud/hertzbeat/general)
Expand Down Expand Up @@ -414,6 +415,8 @@ HertzBeat 赫兹跳动是 [Dromara开源社区](https://dromara.org/) 下顶级

[Github Discussion](https://github.com/dromara/hertzbeat/discussions)

[Reddit Community](https://www.reddit.com/r/hertzbeat/)

[User Club](https://support.qq.com/products/379369)

[Follow Us Twitter](https://twitter.com/hertzbeat1024)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,9 @@ public interface AlertDefineDao extends JpaRepository<AlertDefine, Long>, JpaSpe
* Query app metric alert define
* @param app app
* @param metric metric
* @param field field
* @return alert define
*/
List<AlertDefine> queryAlertDefineByAppAndMetricAndField(String app, String metric, String field);
List<AlertDefine> queryAlertDefineByAppAndMetric(String app, String metric);

/**
* Query the alarm definition list associated with the monitoring ID
Expand Down
3 changes: 2 additions & 1 deletion home/docs/others/developer.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@ sidebar_label: Contributors
<tr>
<td align="center" valign="top" width="14.28%"><a href="https://github.com/zqr10159"><img src="https://avatars.githubusercontent.com/u/30048352?v=4?s=100" width="100px;" alt="zqr10159"/><br /><sub><b>Logic</b></sub></a><br /><a href="https://github.com/dromara/hertzbeat/commits?author=zqr10159" title="Documentation">📖</a> <a href="https://github.com/dromara/hertzbeat/commits?author=zqr10159" title="Code">💻</a><a href="#design-Ceilzcx" title="Design">🎨</a></td>
<td align="center" valign="top" width="14.28%"><a href="https://github.com/vinci-897"><img src="https://avatars.githubusercontent.com/u/55838224?v=4?s=100" width="100px;" alt="vinci"/><br /><sub><b>vinci</b></sub></a><br /><a href="https://github.com/dromara/hertzbeat/commits?author=vinci-897" title="Code">💻</a> <a href="https://github.com/dromara/hertzbeat/commits?author=vinci-897" title="Documentation">📖</a> <a href="#design-vinci-897" title="Design">🎨</a></td>
</tr>
<td align="center" valign="top" width="14.28%"><a href="https://github.com/a-little-fool"><img src="https://avatars.githubusercontent.com/u/105542329?v=4?s=100" width="100px;" alt="淞筱"/><br /><sub><b>淞筱</b></sub></a><br /><a href="https://github.com/dromara/hertzbeat/commits?author=a-little-fool" title="Code">💻</a> <a href="https://github.com/dromara/hertzbeat/commits?author=a-little-fool" title="Documentation">📖</a> <a href="#design-a-little-fool" title="Design">🎨</a></td>
</tr>
</tbody>
</table>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ sidebar_label: 开发者们
<tr>
<td align="center" valign="top" width="14.28%"><a href="https://github.com/zqr10159"><img src="https://avatars.githubusercontent.com/u/30048352?v=4?s=100" width="100px;" alt="zqr10159"/><br /><sub><b>Logic</b></sub></a><br /><a href="https://github.com/dromara/hertzbeat/commits?author=zqr10159" title="Documentation">📖</a> <a href="https://github.com/dromara/hertzbeat/commits?author=zqr10159" title="Code">💻</a><a href="#design-Ceilzcx" title="Design">🎨</a></td>
<td align="center" valign="top" width="14.28%"><a href="https://github.com/vinci-897"><img src="https://avatars.githubusercontent.com/u/55838224?v=4?s=100" width="100px;" alt="vinci"/><br /><sub><b>vinci</b></sub></a><br /><a href="https://github.com/dromara/hertzbeat/commits?author=vinci-897" title="Code">💻</a> <a href="https://github.com/dromara/hertzbeat/commits?author=vinci-897" title="Documentation">📖</a> <a href="#design-vinci-897" title="Design">🎨</a></td>
<td align="center" valign="top" width="14.28%"><a href="https://github.com/a-little-fool"><img src="https://avatars.githubusercontent.com/u/105542329?v=4?s=100" width="100px;" alt="淞筱"/><br /><sub><b>淞筱</b></sub></a><br /><a href="https://github.com/dromara/hertzbeat/commits?author=a-little-fool" title="Code">💻</a> <a href="https://github.com/dromara/hertzbeat/commits?author=a-little-fool" title="Documentation">📖</a> <a href="#design-a-little-fool" title="Design">🎨</a></td>
</tr>
</tbody>
</table>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ public void run(String... args) throws Exception {
Set<String> apps = appService.getAllAppDefines().keySet();
for (String app : apps) {
try {
List<AlertDefine> defines = alertDefineDao.queryAlertDefineByAppAndMetricAndField(app, CommonConstants.AVAILABILITY, null);
List<AlertDefine> defines = alertDefineDao.queryAlertDefineByAppAndMetric(app, CommonConstants.AVAILABILITY);
if (defines.isEmpty()) {
AlertDefine alertDefine = AlertDefine.builder()
.app(app)
Expand Down

0 comments on commit 36c40fc

Please sign in to comment.