Skip to content

Commit

Permalink
sop url: fix job down urls
Browse files Browse the repository at this point in the history
  • Loading branch information
eguzki committed Jan 20, 2021
1 parent ac3344e commit 1a3497a
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion pkg/3scale/amp/component/apicast_monitoring.go
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ func (apicast *Apicast) ApicastPrometheusRules() *monitoringv1.PrometheusRule {
{
Alert: "ThreescaleApicastJobDown",
Annotations: map[string]string{
"sop_url": ThreescalePodNotReadyURL,
"sop_url": ThreescalePrometheusJobDownURL,
"summary": "Job {{ $labels.job }} on {{ $labels.namespace }} is DOWN",
"description": "Job {{ $labels.job }} on {{ $labels.namespace }} is DOWN",
},
Expand Down
4 changes: 2 additions & 2 deletions pkg/3scale/amp/component/backend_monitoring.go
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ func (backend *Backend) BackendWorkerPrometheusRules() *monitoringv1.PrometheusR
{
Alert: "ThreescaleBackendWorkerJobDown",
Annotations: map[string]string{
"sop_url": ThreescalePodNotReadyURL,
"sop_url": ThreescalePrometheusJobDownURL,
"summary": "Job {{ $labels.job }} on {{ $labels.namespace }} is DOWN",
"description": "Job {{ $labels.job }} on {{ $labels.namespace }} is DOWN",
},
Expand Down Expand Up @@ -138,7 +138,7 @@ func (backend *Backend) BackendListenerPrometheusRules() *monitoringv1.Prometheu
{
Alert: "ThreescaleBackendListenerJobDown",
Annotations: map[string]string{
"sop_url": ThreescalePodNotReadyURL,
"sop_url": ThreescalePrometheusJobDownURL,
"summary": "Job {{ $labels.job }} on {{ $labels.namespace }} is DOWN",
"description": "Job {{ $labels.job }} on {{ $labels.namespace }} is DOWN",
},
Expand Down
1 change: 1 addition & 0 deletions pkg/3scale/amp/component/generic_monitoring.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import (

// Add alert sop urls here
const (
ThreescalePrometheusJobDownURL = "https://github.com/3scale/3scale-Operations/blob/master/sops/alerts/prometheus_job_down.adoc"
ThreescalePodNotReadyURL = "https://github.com/3scale/3scale-Operations/blob/master/sops/alerts/pod_not_ready.adoc"
ThreescaleZync5XXRequestsHighURL = "https://github.com/3scale/3scale-Operations/blob/master/sops/alerts/zync_5xx_requests_high.adoc"
ThreescaleZyncQueScheduledJobCountHighURL = "https://github.com/3scale/3scale-Operations/blob/master/sops/alerts/zync_que_scheduled_job_count_high.adoc"
Expand Down
1 change: 1 addition & 0 deletions pkg/3scale/amp/component/system_monitoring.go
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,7 @@ func (system *System) SystemAppPrometheusRules() *monitoringv1.PrometheusRule {
{
Alert: "ThreescaleSystemApp5XXRequestsHigh",
Annotations: map[string]string{
"sop_url": ThreescaleApicastLatencyHighURL,
"summary": "Job {{ $labels.job }} on {{ $labels.namespace }} has more than 50 HTTP 5xx requests in the last minute",
"description": "Job {{ $labels.job }} on {{ $labels.namespace }} has more than 50 HTTP 5xx requests in the last minute",
},
Expand Down
4 changes: 2 additions & 2 deletions pkg/3scale/amp/component/zync_monitoring.go
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ func (zync *Zync) ZyncPrometheusRules() *monitoringv1.PrometheusRule {
{
Alert: "ThreescaleZyncJobDown",
Annotations: map[string]string{
"sop_url": ThreescalePodNotReadyURL,
"sop_url": ThreescalePrometheusJobDownURL,
"summary": "Job {{ $labels.job }} on {{ $labels.namespace }} is DOWN",
"description": "Job {{ $labels.job }} on {{ $labels.namespace }} is DOWN",
},
Expand Down Expand Up @@ -125,7 +125,7 @@ func (zync *Zync) ZyncQuePrometheusRules() *monitoringv1.PrometheusRule {
{
Alert: "ThreescaleZyncQueJobDown",
Annotations: map[string]string{
"sop_url": ThreescalePodNotReadyURL,
"sop_url": ThreescalePrometheusJobDownURL,
"summary": "Job {{ $labels.job }} on {{ $labels.namespace }} is DOWN",
"description": "Job {{ $labels.job }} on {{ $labels.namespace }} is DOWN",
},
Expand Down

0 comments on commit 1a3497a

Please sign in to comment.