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
0
Merge Requests
0
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
Léo-Paul Géneau
gitlab-ce
Commits
6cd912ba
Commit
6cd912ba
authored
Sep 06, 2017
by
Pawel Chojnacki
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix measure codde to work with seconds
parent
40e9fbb2
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
lib/gitlab/metrics/influx_db.rb
lib/gitlab/metrics/influx_db.rb
+2
-2
No files found.
lib/gitlab/metrics/influx_db.rb
View file @
6cd912ba
...
...
@@ -102,8 +102,8 @@ module Gitlab
real_time
=
(
real_stop
-
real_start
)
*
1000.0
cpu_time
=
cpu_stop
-
cpu_start
Gitlab
::
Metrics
.
histogram
(
"gitlab_
#{
name
}
_real_duration
"
.
to_sym
,
"Measure
#{
name
}
"
,
{},
[
1
,
2
,
5
,
10
,
20
,
50
,
100
,
1000
]).
observe
({},
real_time
)
Gitlab
::
Metrics
.
histogram
(
"gitlab_
#{
name
}
_cpu_duration
"
.
to_sym
,
"Measure
#{
name
}
"
,
{},
[
1
,
2
,
5
,
10
,
20
,
50
,
100
,
1000
]).
observe
({},
cpu_time
)
Gitlab
::
Metrics
.
histogram
(
"gitlab_
#{
name
}
_real_duration
_seconds"
.
to_sym
,
"Measure
#{
name
}
"
,
{},
[
0.01
,
0.02
,
0.05
,
0.1
,
0.2
,
0.5
,
1
,
2
]).
observe
({},
real_time
/
1000.0
)
Gitlab
::
Metrics
.
histogram
(
"gitlab_
#{
name
}
_cpu_duration
_seconds"
.
to_sym
,
"Measure
#{
name
}
"
,
{},
[
0.01
,
0.02
,
0.05
,
0.1
,
0.2
,
0.5
,
1
,
2
]).
observe
({},
cpu_time
/
1000.0
)
trans
.
increment
(
"
#{
name
}
_real_time"
,
real_time
,
false
)
trans
.
increment
(
"
#{
name
}
_cpu_time"
,
cpu_time
,
false
)
...
...
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