Skip to content
GitLab
Next
Menu
Why GitLab
Pricing
Contact Sales
Explore
Why GitLab
Pricing
Contact Sales
Explore
Sign in
Get free trial
Primary navigation
Search or go to…
Project
Runbooks
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Requirements
Custom issue tracker
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Privacy statement
Keyboard shortcuts
?
What's new
6
Snippets
Groups
Projects
Show more breadcrumbs
GitLab.com
Runbooks
Commits
016de10c
Verified
Commit
016de10c
authored
1 year ago
by
Tomasz Maczukin
💬
Browse files
Options
Downloads
Patches
Plain Diff
Add 'Idle Efficiency' graph to ci-runners autoscaling dashboard
parent
0631b266
No related branches found
Branches containing commit
No related tags found
Tags containing commit
Loading
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
dashboards/ci-runners/incident-autoscaling.dashboard.jsonnet
+1
-0
1 addition, 0 deletions
dashboards/ci-runners/incident-autoscaling.dashboard.jsonnet
libsonnet/stage-groups/verify-runner/autoscaling_graphs.libsonnet
+31
-0
31 additions, 0 deletions
...t/stage-groups/verify-runner/autoscaling_graphs.libsonnet
with
32 additions
and
0 deletions
dashboards/ci-runners/incident-autoscaling.dashboard.jsonnet
+
1
−
0
View file @
016de10c
...
...
@@ -44,6 +44,7 @@ dashboardIncident.incidentDashboard(
.
addGrid
(
panels
=[
autoscalingGraphs
.
vmStates
(),
autoscalingGraphs
.
idleEfficiency
(),
autoscalingGraphs
.
vmOperationsRate
(),
autoscalingGraphs
.
vmCreationTiming
(),
],
...
...
This diff is collapsed.
Click to expand it.
libsonnet/stage-groups/verify-runner/autoscaling_graphs.libsonnet
+
31
−
0
View file @
016de10c
...
...
@@ -2,6 +2,7 @@ local panels = import './panels.libsonnet';
local
basic
=
import
'grafana/basic.libsonnet'
;
local
promQuery
=
import
'grafana/prom_query.libsonnet'
;
local
seriesOverrides
=
import
'grafana/series_overrides.libsonnet'
;
local
thresholds
=
import
'gitlab-dashboards/thresholds.libsonnet'
;
local
runnersManagerMatching
=
import
'./runner_managers_matching.libsonnet'
;
...
...
@@ -45,6 +46,35 @@ local vmCreationTiming(partition=runnersManagerMatching.defaultPartition) =
intervalFactor
=
2
,
);
local
idleEfficiency
(
partition
=
runnersManagerMatching
.
defaultPartition
)
=
basic
.
timeseries
(
'Idle efficiency'
,
legendFormat
=
'{{shard}}'
,
format
=
'percentunit'
,
query
=
runnersManagerMatching
.
formatQuery
(
|||
1 - (
sum by(shard) (
gitlab_runner_autoscaling_machine_states{environment=~"$environment", stage=~"$stage", executor="docker+machine", %(runnerManagersMatcher)s, state=~"idle|acquired"}
)
/
sum by(shard) (
gitlab_runner_autoscaling_machine_states{environment=~"$environment", stage=~"$stage", executor="docker+machine", %(runnerManagersMatcher)s}
)
)
|||
,
partition
),
description
=
|||
Shows what percentages of instances are in the idle or acquired state. There is no golden rule here and the metric
should be analyzed together with raw numbers showing the different instance states, but in a very generlized view:
the higher number the better, more than 50% is what we aim to if there is a constant number of jobs in the
incoming queue for a shard. For shards that have times with no jobs in the queue, having the efficiency dropped
below 50% is something normal, but in that case we aim to have a small raw number of idle instances.
|||
,
thresholds
=[
thresholds
.
warningLevel
(
'lt'
,
0.5
),
thresholds
.
optimalLevel
(
'gt'
,
0.5
),
],
);
local
gcpRegionQuotas
=
basic
.
timeseries
(
'GCP region quotas'
,
...
...
@@ -105,6 +135,7 @@ local gcpInstances =
vmStates
::
vmStates
,
vmOperationsRate
::
vmOperationsRate
,
vmCreationTiming
::
vmCreationTiming
,
idleEfficiency
::
idleEfficiency
,
gcpRegionQuotas
::
gcpRegionQuotas
,
gcpInstances
::
gcpInstances
,
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment