• Applicable Software: MokoGIT
  • Min Version Number: 02.89.01
  • Max Version Number: Not Applicable

Why this matters

Before this feature, a runner list told you a runner was online but not whether it was doing anything, and the Actions queue told you a job was running but not on which machine. Diagnosing a wedged runner or a capacity shortage meant opening the runner edit page, scrolling its task history, and mentally correlating timestamps with the queue. The Current-Job column and its reciprocal Runner column collapse that correlation into the two tables you were already looking at.

This is a diagnosis tool for operators. A runner that shows Running but whose job has been going far longer than expected is a candidate for a wedge; a queue full of waiting jobs while several runners sit idle points at a label-matching or capacity problem rather than a stuck machine.

How it works

When MokoGIT renders a runner list it collects the IDs of every runner on the page and issues one batched query for the in-progress task of each - not one query per runner. The lookup selects tasks whose status is running and whose runner ID is in that set, loads each task's job, run, and repository in the same pass, and returns a map keyed by runner ID. A runner with no running task is simply absent from the map, so the common idle case costs nothing extra. This single-query design is what makes the column safe to show on a list of a hundred runners.

The Actions queue does the mirror operation. For the running jobs on the page it collects their current task IDs and batch-loads the runner executing each (a single pair of queries - tasks, then runners - with no N+1), then attaches the runner's name to each queue row.

Viewer-scoped detail - the cross-tenant guard

Runners are often shared: a single machine can execute jobs for many repositories across many organizations. That creates a visibility problem on the organization, user, and repository runner pages, where a shared runner might be busy with a job for a repository you have no access to. MokoGIT resolves this by gating the detail, not the busy state:

  • Admin view - sees every running job's full detail.
  • Repository view - sees job detail only for tasks belonging to that repository.
  • Organization / user view - sees job detail only for tasks whose repository owner is the current owner.

When a runner is busy with a job outside your scope, the column still shows a neutral Busy (hidden) marker (with the tooltip "This runner is executing a job outside your scope; details are hidden") so you know the slot is occupied, but the repository, workflow, run, and job name are withheld. The busy state itself is always safe to show - it only says the slot is taken. The task carries its repository ID and owner ID from the moment it is created, so this scoping needs no extra lookup; it is a pure in-memory check against the view you are on.

Reading the Current-Job column

In a runner row, the status cell shows a blue Running badge when the runner is busy (replacing the usual online/offline label), and the Current Job cell shows one of three things:

  • A linked job - when you are authorized for the task. It reads as repository then workflow #run then / job-name, links straight to that job's log view, and shows how long the job has been running underneath. Click it to jump directly to the live job.
  • Busy (hidden) - when the runner is executing a job outside your scope (see the cross-tenant guard above).
  • A dash (-) - when the runner is idle.

Reading the queue Runner column

Open the Actions queue (admin: Site Administration, then Actions, then Queue). Each row that is running shows a Runner column with a small server icon and the runner's name (tooltip "Running on this runner"). Waiting, blocked, and held rows show a dash, because they are not on a runner yet - which is itself the signal that they are queued, not executing. Because the queue already access-filters the jobs you can see before it attaches runner names, no extra cross-tenant gating is needed in this direction: if you can see the job, you can see the runner it is on.

Step-by-step: diagnose a wedge or capacity gap

  1. Open the runner list for the scope you manage (admin for the whole fleet).
  2. Scan the status column for blue Running badges to see which runners are occupied right now.
  3. For each running runner, read the Current Job cell and the elapsed time beneath it. A job running far longer than its workflow normally takes is a wedge candidate.
  4. Click the job link to open its live log and confirm whether it is progressing or hung.
  5. Cross-check from the other side: open the Actions queue and read the Runner column. If many jobs are waiting while runners sit idle, the problem is label matching or capacity, not a stuck machine.
  6. If a runner is genuinely wedged, drain it with maintenance mode (it finishes its current job, then stops picking up new work) before restarting it.

For automation: the API

The web columns are a presentation of data already available through the Actions API. To find what a runner is doing, or which runner a job is on, read the tasks list and correlate on runner ID and status:

# List runners for an org (status, labels, last-online)
curl -H "Authorization: token YOUR_TOKEN" \
  https://git.mokoenterprises.us/api/v1/orgs/YourOrg/actions/runners

# List recent tasks (each task carries its runner id and status)
curl -H "Authorization: token YOUR_TOKEN" \
  https://git.mokoenterprises.us/api/v1/repos/YourOrg/YourRepo/actions/tasks

A task whose status is running names the runner currently executing it; that is the same correlation the web tables perform server-side.

Caveats

  • The Current-Job column reflects running tasks only. A runner that is online but idle shows a dash; a runner that just finished a job shows idle until it picks up the next one.
  • The Busy (hidden) state is not an error - it is the privacy guard doing its job on a shared runner. Only a scope that owns the task (admin, the task's repository, or the task's owner) sees the job detail.
  • In the rare case where a runner appears to have more than one running task, the first one found is shown.
  • Both tables are a point-in-time render. To watch them update without reloading, rely on the 15-second live refresh (see the companion article on queue and runner live refresh).

Get help

Open a support ticket or call (931) 820-0265.