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
Jérome Perrin
gitlab-ce
Commits
33b66f9c
Commit
33b66f9c
authored
Jun 15, 2016
by
Patricio Cano
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Correct Sidekiq Metrics Docs
parent
8ad18845
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
152 additions
and
0 deletions
+152
-0
doc/api/sidekiq_metrics.md
doc/api/sidekiq_metrics.md
+152
-0
No files found.
doc/api/sidekiq_metrics.md
0 → 100644
View file @
33b66f9c
# Sidekiq Metrics
>**Note:** This endpoint is only available on GitLab 8.9 and above.
This API endpoint allows you to retrieve some information about the current state
of Sidekiq, its jobs, queues, and processes.
## Get the current Queue Metrics
List information about all the registered queues, their backlog and their
latency.
```
GET /sidekiq/queue_metrics
```
```
bash
curl
-H
"PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK"
https://gitlab.example.com/api/v3/sidekiq/queue_metrics
```
Example response:
```
json
{
"queues"
:
{
"default"
:
{
"backlog"
:
0
,
"latency"
:
0
}
}
}
```
## Get the current Process Metrics
List information about all the Sidekiq workers registered to process your queues.
```
GET /sidekiq/process_metrics
```
```
bash
curl
-H
"PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK"
https://gitlab.example.com/api/v3/sidekiq/process_metrics
```
Example response:
```
json
{
"processes"
:
[
{
"hostname"
:
"gitlab.example.com"
,
"pid"
:
5649
,
"tag"
:
"gitlab"
,
"started_at"
:
"2016-06-14T10:45:07.159-05:00"
,
"queues"
:
[
"post_receive"
,
"mailers"
,
"archive_repo"
,
"system_hook"
,
"project_web_hook"
,
"gitlab_shell"
,
"incoming_email"
,
"runner"
,
"common"
,
"default"
],
"labels"
:
[],
"concurrency"
:
25
,
"busy"
:
0
}
]
}
```
## Get the current Job Statistics
List information about the jobs that Sidekiq has performed.
```
GET /sidekiq/job_stats
```
```
bash
curl
-H
"PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK"
https://gitlab.example.com/api/v3/sidekiq/job_stats
```
Example response:
```
json
{
"jobs"
:
{
"processed"
:
2
,
"failed"
:
0
,
"enqueued"
:
0
}
}
```
## Get a compound response of all the previously mentioned metrics
List all the currently available information about Sidekiq.
```
GET /sidekiq/compound_metrics
```
```
bash
curl
-H
"PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK"
https://gitlab.example.com/api/v3/sidekiq/compound_metrics
```
Example response:
```
json
{
"queues"
:
{
"default"
:
{
"backlog"
:
0
,
"latency"
:
0
}
},
"processes"
:
[
{
"hostname"
:
"gitlab.example.com"
,
"pid"
:
5649
,
"tag"
:
"gitlab"
,
"started_at"
:
"2016-06-14T10:45:07.159-05:00"
,
"queues"
:
[
"post_receive"
,
"mailers"
,
"archive_repo"
,
"system_hook"
,
"project_web_hook"
,
"gitlab_shell"
,
"incoming_email"
,
"runner"
,
"common"
,
"default"
],
"labels"
:
[],
"concurrency"
:
25
,
"busy"
:
0
}
],
"jobs"
:
{
"processed"
:
2
,
"failed"
:
0
,
"enqueued"
:
0
}
}
```
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