跳到正文
Penstock

Guide / Test and run

Check Workers

Check Workers asks your engine whether anything picks up the tasks your diagrams hand out, before your users find out.

ProTeam in a pipeline

此内容尚不支持你的语言。

A service task does not do the work itself. A worker, a program of yours, does. On Camunda 8 the task names a job type. On Camunda 7 it names a topic. If no worker is running for that name, the task waits forever. Check Workers finds that out.

The workers it asks about are the ones Code links finds in your code, in Java, Kotlin, Groovy, Scala, JavaScript, TypeScript, Python, Go and C#. For Python, Go, C# and Scala they are read through the penstock command line. Once a worker is listed, its job type or topic has Go to code, Runs in and usages at each line that raises it.

Run Check Workers on the workers of your project. Penstock asks each diagram's engine, using the profile in force for that diagram's folder. A project with a Camunda 7 folder and a Camunda 8 folder asks both. Each worker then says what the engine said, and the workers node shows when the check ran, for example checked at 14:02.

Run Check Workers in your tool

JetBrains

  1. Open the Penstock tool window and find Workers.
  2. Right-click Workers, or select it and use its action: Check Workers on <engine>. If your project uses several engines it says Check Workers on the Engines.

VS Code

  1. Open the Penstock view in the Activity Bar and find Workers.
  2. Right-click Workers, or select it and use its action: Check Workers. It queries the engine of the profile in force.

Command line

Not available on the command line. There is no command for it yet. penstock code compares diagrams with code, without asking an engine.

Engine Answer Meaning
Camunda 8.9 and later 3 workers took its jobs in the last 24 hours All is well.
Camunda 8.9 and later 5 jobs in the last 24 hours and no worker took one Nobody picks up this job type. The worker is marked with a warning.
Camunda 8.9 and later no jobs in the last 24 hours Nothing to judge.
Camunda 7, Operaton, CIB seven a worker is working on its tasks All is well.
Camunda 7, Operaton, CIB seven tasks wait and no worker has locked one Nobody subscribes to this topic. The worker is marked with a warning.
Camunda 7, Operaton, CIB seven no open tasks Nothing to judge.

The check only reads. It sends these requests to the engine address of the profile, and changes nothing there:

Engine Request What it is used for
Camunda 8 POST /jobs/statistics/by-types, one request for all job types of the project, for the last 24 hours Per job type, the number of jobs created and the number of workers that took them
Camunda 7, Operaton, CIB seven GET /external-task/topic-names?withUnlockedTasks=true and GET /external-task/topic-names?withLockedTasks=true The topics that have open tasks, and the topics that have a task a worker has locked

The names it looks up are the job types and topics of the service tasks and similar steps in your diagrams. A step with a delegate class, an expression or a bean has no worker to ask for, and is not part of it.

The result is shown on the worker, in the workers node of your tool's project view. It is not written to a file. A request the engine answers with an error stops the check and says why: for Camunda 8 a 404 means the engine has no job statistics, and a 401 or 403 means the profile's user may not read them.

Only when you run it, with the profile's credentials. See Security and privacy.

Check Workers is part of Pro's code links. The code check, which compares diagrams with your code and does not ask an engine, is described on its own page.

"The engine does not report job statistics, which it does from Camunda 8.9".
Your Camunda 8 is older than 8.9. Use the code check instead. It compares diagrams with your code.
"The engine refused the question (403)".
The profile's user may not read jobs. Use a user that may.
There is no Check Workers action.
The project has no worker tasks yet, or Pro is not active. Without Pro a Code line offers to buy or sign in.
It says "no jobs" for a worker that runs.
Only the last 24 hours count on Camunda 8, and only open tasks on Camunda 7. A quiet worker looks quiet.