Skip to content

Commit

Permalink
Fill in the SQL statements that are missing from the alarm (DataLinkD…
Browse files Browse the repository at this point in the history
…C#2574)

* Optimize the process

* Fill in the SQL statements that are missing from the alarm

* Fill in the SQL statements that are missing from the alarm
  • Loading branch information
gaoyan1998 authored Nov 25, 2023
1 parent c56784b commit cb88b63
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 9 deletions.
2 changes: 1 addition & 1 deletion dinky-admin/src/main/resources/application.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ spring:
# If you use pgsql database, please configure pgsql database connection information in application-pgsql.yml
# If you use the h2 database, please configure the h2 database connection information in application-h2.yml,
# note: the h2 database is only for experience use, and the related data that has been created cannot be migrated, please use it with caution
active: h2 #[h2,mysql,pgsql]
active: ${DB_ACTIVE:h2} #[h2,mysql,pgsql]
include: jmx

# mvc config
Expand Down
17 changes: 9 additions & 8 deletions script/sql/upgrade/1.0.0-SNAPSHOT_schema/mysql/dinky_dml.sql
Original file line number Diff line number Diff line change
Expand Up @@ -220,15 +220,16 @@ INSERT INTO dinky_alert_rules (id, name, rule, template_id, rule_type, trigger_c
INSERT INTO dinky_alert_rules (id, name, rule, template_id, rule_type, trigger_conditions, description, enabled, create_time, update_time, creator, updater) VALUES (6, 'alert.rule.checkpointFail', '[{"ruleKey":"isCheckpointFailed","ruleOperator":"EQ","ruleValue":"true"}]', 1, 'SYSTEM', ' or ', '', 1, '1970-01-01 00:00:00', '2023-11-22 17:03:44', null, null);
INSERT INTO dinky_alert_rules (id, name, rule, template_id, rule_type, trigger_conditions, description, enabled, create_time, update_time, creator, updater) VALUES (7, 'alert.rule.jobRunException', '[{"ruleKey":"isException","ruleOperator":"EQ","ruleValue":"true"}]', 1, 'SYSTEM', ' or ', '', 1, '1970-01-01 00:00:00', '2023-11-22 17:03:44', null, null);

INSERT INTO dinky_alert_template VALUES (1, 'Default', '
- **Job Name :** <font color=''gray''>${task.name}</font>
- **Job Status :** <font color=''red''>${jobInstance.status}</font>
- **Alert Time :** ${time}
- **Start Time :** ${startTime}
- **End Time :** ${endTime}
- **<font color=''red''>${(exceptions.rootException)?substring(0,20)}</font>**

INSERT INTO dinky_alert_template (id, name, template_content, enabled, create_time, update_time, creator, updater) VALUES (1, 'Default', '
- **Job Name :** <font color=\'gray\'>${jobName}</font>
- **Job Status :** <font color=\'red\'>${jobStatus}</font>
- **Alert Time :** ${alertTime}
- **Start Time :** ${jobStartTime}
- **End Time :** ${jobEndTime}
- **<font color=\'red\'>${errorMsg}</font>**
[Go toTask Web](http://${taskUrl})
', 1, null, null,null,null);
', 1, '2023-11-20 17:45:48', '2023-11-23 00:14:22', null, 1);

COMMIT;

Expand Down

0 comments on commit cb88b63

Please sign in to comment.