![Saša Živkov](/assets/img/avatar_default.png)
When the new option --by-queue is used the output of the show-queue command is grouped by the work queue. Queue name is printed on top of the tasks list and the number of worker threads assigned to that thread pool is printed in the summary line. This option should help Gerrit admins to identify which thread pools need to be adjusted. For comparison, here is an example output without the new --by-queue option: Task State StartTime Command ------------------------------------------------------------------------------ 9d51b721 16:29:14.750 git-upload-pack '/gerrit' (admin) 18fr4561 16:29:14.750 git-upload-pack '/gerrit' (admin) ad52b823 16:29:14.750 git-upload-pack '/gerrit' (admin) bd51bbcc 16:29:14.750 git-upload-pack '/gerrit' (admin) 11223344 16:29:14.750 git-upload-pack '/gerrit' (admin) 3d120b5c 17:28:20.169 16:28:20.169 Log File Compressor ------------------------------------------------------------------------------ 6 tasks With the --by-queue option the output looks like: $ ssh -p29418 admin@localhost gerrit show-queue -w --by-queue Task State StartTime Command ------------------------------------------------------------------------------ Queue: SSH-Interactive-Worker 9d51b721 16:29:14.750 git-upload-pack '/gerrit' (admin) 18fr4561 16:29:14.750 git-upload-pack '/gerrit' (admin) ad52b823 16:29:14.750 git-upload-pack '/gerrit' (admin) bd51bbcc 16:29:14.750 git-upload-pack '/gerrit' (admin) 11223344 16:29:14.750 git-upload-pack '/gerrit' (admin) ------------------------------------------------------------------------------ 5 tasks, 14 worker threads Queue: WorkQueue 3d120b5c 17:28:20.169 16:28:20.169 Log File Compressor ------------------------------------------------------------------------------ 1 tasks, 1 worker threads Change-Id: If82bdb50702f2001f887fe5004b0d80b61131a90
93 lines
2.5 KiB
Plaintext
93 lines
2.5 KiB
Plaintext
= gerrit show-queue
|
|
|
|
== NAME
|
|
gerrit show-queue - Display the background work queues, including replication
|
|
|
|
== SYNOPSIS
|
|
[verse]
|
|
--
|
|
_ssh_ -p <port> <host> _gerrit show-queue_
|
|
_ssh_ -p <port> <host> _ps_
|
|
--
|
|
|
|
== DESCRIPTION
|
|
Presents a table of the pending activity the Gerrit daemon
|
|
is currently performing, or will perform in the near future.
|
|
Gerrit contains an internal scheduler, similar to cron, that it
|
|
uses to queue and dispatch both short and long term activity.
|
|
|
|
Tasks that are completed or canceled exit the queue very quickly
|
|
once they enter this state, but it can be possible to observe tasks
|
|
in these states.
|
|
|
|
== ACCESS
|
|
End-users may see a task in the queue only if they can also see
|
|
the project the task is associated with. Tasks operating on other
|
|
projects, or that do not have a specific project are hidden.
|
|
|
|
Members of the group 'Administrators', or any group that has been
|
|
granted
|
|
link:access-control.html#capability_viewQueue[the 'View Queue' capability]
|
|
can see all queue entries.
|
|
|
|
== SCRIPTING
|
|
Intended for interactive use only.
|
|
|
|
== OPTIONS
|
|
--wide::
|
|
-w::
|
|
Do not format the output to the terminal width (default of
|
|
80 columns).
|
|
|
|
--by-queue::
|
|
-q::
|
|
Group tasks by queue and print queue info.
|
|
|
|
== DISPLAY
|
|
|
|
Task::
|
|
Unique task identifier on this server. May be passed into
|
|
link:cmd-kill.html[kill] to cancel or terminate the task.
|
|
Task identifiers have a period of 2^32-1, and start from
|
|
a random value.
|
|
|
|
State::
|
|
If running, blank.
|
|
+
|
|
If the task has completed, but has not yet been reaped, 'done'.
|
|
If the task has been killed, but has not yet halted or been removed
|
|
from the queue, 'killed'.
|
|
+
|
|
If the task is ready to execute but is waiting for an idle thread
|
|
in its associated thread pool, 'waiting'.
|
|
+
|
|
Otherwise the time (local to the server) that this task will begin
|
|
execution.
|
|
|
|
Command::
|
|
Short text description of the task that will be performed
|
|
at the given time.
|
|
|
|
== EXAMPLES
|
|
|
|
The following queue contains two tasks scheduled to replicate the
|
|
`tools/gerrit.git` project to two different remote systems, `dst1`
|
|
and `dst2`:
|
|
|
|
----
|
|
$ ssh -p 29418 review.example.com gerrit show-queue
|
|
Task State Command
|
|
------------------------------------------------------------------------------
|
|
7aae09b2 14:31:15.435 mirror dst1:/home/git/tools/gerrit.git
|
|
9ad09d27 14:31:25.434 mirror dst2:/var/cache/tools/gerrit.git
|
|
------------------------------------------------------------------------------
|
|
2 tasks
|
|
----
|
|
|
|
GERRIT
|
|
------
|
|
Part of link:index.html[Gerrit Code Review]
|
|
|
|
SEARCHBOX
|
|
---------
|