jobs()

Returns all jobs offered by the server grouped by namespace (engine). Combines krn.EnumNameSpaces (the list of implemented engines) with one krn.EnumJobs call per engine. This issues 1 + N server round-trips, where N is the number of engines; in the async variant the krn.EnumJobs calls run concurrently.

1. Signature

  • Sync

  • Async

ecm.system.jobs() -> dict[str, list[str]]
await ecm.system.jobs() -> dict[str, list[str]]

2. Parameters

None.

3. Return value

A dict[str, list[str]]:

Element Description

Key

Short label of the namespace / engine (e.g. "krn", "dms").

Value

List of that namespace’s jobs including the namespace prefix (e.g. "krn.EnumJobs").

Both the dict keys and each job list are sorted alphabetically.

Which namespaces and jobs are returned depends on the specific server installation and configuration and may differ between systems.

4. Examples

4.1. List all jobs

  • Sync

  • Async

all_jobs = ecm.system.jobs()

print(sorted(all_jobs))
# e.g.: ['abn', 'adm', 'ado', 'cnv', 'dbp', 'dms', 'dtr', 'krn', 'lic', 'mng', 'std', 'vtx', 'wfm']

print(all_jobs["krn"][:3])
# e.g.: ['krn.AppsEventsEnum', 'krn.AppsEventsSubscribe', 'krn.AslogGeneralFlags']
all_jobs = await ecm.system.jobs()

print(sorted(all_jobs))
print(all_jobs["krn"][:3])

4.2. Check whether a specific job is available

all_jobs = ecm.system.jobs()
if "dms.GetResultList" in all_jobs.get("dms", []):
    ...

5. See also

  • info() — statistics on the currently open pool connections