fix(notify): update MYSQL_OUT_OF_SYNC template (#15706)

This commit is contained in:
Zexi Li
2023-01-05 15:39:05 +08:00
committed by GitHub
parent 9d2697c69a
commit 0404b5195a
2 changed files with 34 additions and 2 deletions
@@ -1,2 +1,18 @@
{{- $d := .resource_details -}}
数据库 {{$d.ip}} 的主从同步不一致,请及时检查。
数据库 {{$d.ip}} 的主从同步不一致,请及时检查。
{{ range $status := $d.status }}
数据库 {{$status.ip}} 状态:
{{- if not $status.operator_error }}
- Slave_IO_Running: {{$status.slave_io_running}}
- Slave_SQL_Running: {{$status.slave_sql_running}}
{{- if $status.last_error }}
- Last_Error: {{$status.last_error}}
{{- end -}}
{{- if $status.last_io_error }}
- Last_IO_Error: {{$status.last_io_error}}
{{- end }}
{{else}}
- Operator_Error: {{$status.operator_error}}
{{- end}}
{{end}}
@@ -1,2 +1,18 @@
{{- $d := .resource_details -}}
The primary and secondary synchronization of the database ({{ $d.ip }}) is inconsistent, please check in time.
The primary and secondary synchronization of the database ({{ $d.ip }}) is inconsistent, please check in time.
{{ range $status := $d.status }}
Database {{$status.ip}} status:
{{- if not $status.operator_error }}
- Slave_IO_Running: {{$status.slave_io_running}}
- Slave_SQL_Running: {{$status.slave_sql_running}}
{{- if $status.last_error }}
- Last_Error: {{$status.last_error}}
{{- end -}}
{{- if $status.last_io_error }}
- Last_IO_Error: {{$status.last_io_error}}
{{- end }}
{{else}}
- Operator_Error: {{$status.operator_error}}
{{- end}}
{{end}}