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
a2dd4592
Commit
a2dd4592
authored
Jul 16, 2020
by
Ash McKenzie
Committed by
Dylan Griffith
Jul 16, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update prometheus expected query
parent
89ff97b1
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
3 deletions
+8
-3
spec/migrations/20200511145545_change_variable_interpolation_format_in_common_metrics_spec.rb
...e_variable_interpolation_format_in_common_metrics_spec.rb
+8
-3
No files found.
spec/migrations/20200511145545_change_variable_interpolation_format_in_common_metrics_spec.rb
View file @
a2dd4592
...
...
@@ -23,9 +23,14 @@ RSpec.describe ChangeVariableInterpolationFormatInCommonMetrics, :migration do
end
it
'updates query to use {{}}'
do
expected_query
=
'avg(sum(container_memory_usage_bytes{container_name!="POD",'
\
'pod_name=~"^{{ci_environment_slug}}-(.*)",namespace="{{kube_namespace}}"})'
\
' by (job)) without (job) /1024/1024/1024'
expected_query
=
<<~
EOS
.
chomp
avg(sum(container_memory_usage_bytes{container!="POD",\
pod=~"^{{ci_environment_slug}}-(.*)",namespace="{{kube_namespace}}"}) \
by (job)) without (job) /1024/1024/1024 OR \
avg(sum(container_memory_usage_bytes{container_name!="POD",\
pod_name=~"^{{ci_environment_slug}}-(.*)",namespace="{{kube_namespace}}"}) \
by (job)) without (job) /1024/1024/1024
EOS
migrate!
...
...
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