Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
6ee608c4
Commit
6ee608c4
authored
Apr 08, 2020
by
Sean Arnold
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add gitlab_prometheus_alert_id another field
parent
2ff6707e
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
2 deletions
+4
-2
app/models/prometheus_alert.rb
app/models/prometheus_alert.rb
+2
-1
spec/models/prometheus_alert_spec.rb
spec/models/prometheus_alert_spec.rb
+2
-1
No files found.
app/models/prometheus_alert.rb
View file @
6ee608c4
...
@@ -56,7 +56,8 @@ class PrometheusAlert < ApplicationRecord
...
@@ -56,7 +56,8 @@ class PrometheusAlert < ApplicationRecord
"for"
=>
"5m"
,
"for"
=>
"5m"
,
"labels"
=>
{
"labels"
=>
{
"gitlab"
=>
"hook"
,
"gitlab"
=>
"hook"
,
"gitlab_alert_id"
=>
prometheus_metric_id
"gitlab_alert_id"
=>
prometheus_metric_id
,
"gitlab_prometheus_alert_id"
=>
id
}
}
}
}
end
end
...
...
spec/models/prometheus_alert_spec.rb
View file @
6ee608c4
...
@@ -96,7 +96,8 @@ describe PrometheusAlert do
...
@@ -96,7 +96,8 @@ describe PrometheusAlert do
"for"
=>
"5m"
,
"for"
=>
"5m"
,
"labels"
=>
{
"labels"
=>
{
"gitlab"
=>
"hook"
,
"gitlab"
=>
"hook"
,
"gitlab_alert_id"
=>
metric
.
id
"gitlab_alert_id"
=>
metric
.
id
,
"gitlab_prometheus_alert_id"
=>
subject
.
id
})
})
end
end
end
end
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment