Scheduler database

The scheduler service holds everything about jobs, slices, Compute Groups and workers. Connect with jnu.connect('scheduler', keystore). Every table below is listed with the policy name you pass as table, who can read it, which columns can be changed, and what each column means.

Column types are the ormdb types from the schema. In JavaScript they arrive as:

Schema type

JavaScript value

id, int53, integer, uinteger, float

number

string, string64k, identifier, opaqueId, URI

string

timestamp, autoNow

Date

unixTime

number, seconds since the epoch

ethAddress

Address from dcp/wallet; use String(value) for the hex form and value.eq(other) to compare

finNum

BigNumber; use .toNumber() or String(value)

json

the parsed value, or null

boolean

boolean

“Owner” in the access column means the identity that signs the query, after proxy-key resolution (see Identity and access). “Via job” means the row is reachable only through a job whose owner is you; “via Compute Group” and “via credentials list” work the same way through computeGroups.owner and credsList.owner.

Jobs

jobs

One row per job. Read by the job owner; the owner can change name, description and link and nothing else. Rows can’t be added or deleted through Jnu.

Column

Type

Meaning

id

autoId

Primary key. The other job tables refer to this number as jobId (or as id for the one-to-one tables).

opaqueId

identifier

Public job id, the value of job.id in the Compute API and in the Portal.

status

string

new, estimation, running, paused, finished, cancelled or corrupted.

owner

ethAddress

Identity that owns the job, that is, the root identity behind the key that deployed it.

address

ethAddress

The job’s escrow account.

paymentAccount

ethAddress

Bank account the escrow is funded from.

startTime

timestamp

When the job was created.

endTime

timestamp

When the job was finalized, or null.

lastUpdate

autoNow

Last change to this row.

lastSliceNumber

int53

Index of the last slice. For a job with a fixed input set this is the slice count.

nextSliceNumber

int53

Next slice to hand out. nextSliceNumber - 1 slices have been distributed.

maxSlicesPerTask

integer

Hard cap on slices per task.

absoluteSlicePayment

finNum

Fixed offer per slice, in DCC.

mvMultSlicePayment

finNum

Market-value multiplier. A job deployed with compute.marketValue(f) stores f here and 0 in absoluteSlicePayment. As of 2026-10-03 the market value is a constant 0.001 DCC per slice; a computed market rate is planned.

duplicationLevel

float

1.0 sends each slice once; 2.0 sends every slice twice; 1.5 sends half of them twice.

duplicationType

string

How duplicates are resolved: race or consensus.

flags

uinteger

Bit flags: 1 localExec, 2 open (slices can still be added), 4 workerConsole, 8 greedyEstimation, 16 discrete, 32 useStrict, 64 nsf (insufficient funds).

needCapabilities

uinteger

Worker capabilities the job needs. Bit flags: 1 v8, 2 spidermonkey, 4 browser, 8 offscreenCanvas, 16 fdlibm, 32 webgpu, 64 KVINv9.

requirements

json

Deprecated. Use needCapabilities.

dataStorageType

string

How to read dataStorageDetails: range, pattern or values.

dataStorageDetails

string64k

Range object, URL pattern or values describing the input set.

resultStorageType

string

How to read resultStorageDetails.

resultStorageDetails

string64k

Where results go.

resultStorageParams

json

POST parameters used with resultStorageDetails when it’s a URL.

name

string

Public name, from job.public.name. Changeable.

description

string

Public description. Changeable.

link

string

Public URL. Changeable.

worktime

string

The runtime environment (worktime) the job runs in, for example map-basic or pyodide.

worktimeVersion

string

Semver range for that environment.

jobs_public

The same table, readable by anyone with any identity. Only opaqueId, name, description and link are returned, and opaqueId is the only column a prototype may filter on.

Warning

As of 2026-10-03 an empty prototype is accepted and returns the public fields of every job on the scheduler. This is expected to change; until it does, don’t put anything in a job’s name, description or link that shouldn’t be world-readable.

jobPerfData

One row per job, keyed by id = jobs.id. Read by the job owner. Written by the scheduler on every result, without locking, so values can be slightly off after a crash. Query it with prototype: { id: job.id }; it has no jobId column.

Column

Type

Meaning

id

primaryId

jobs.id.

lastUpdate

autoNow

Last change.

estimationSlicesRemaining

int53

Estimation slices not yet handed out. The job leaves estimation when this reaches zero (default 3 slices).

measuredSlices

integer

Results that have contributed to the averages, including duplicates.

taskCount

integer

Tasks that included at least one slice of this job.

returnCount

integer

Slices given back by workers without being worked on.

retaskedCount

integer

Slices re-issued by the watchdog.

tooSlowCount, noProgressCount, uncaughtCount

integer

Worker-reported failure counts.

sliceCPUTime, sliceGPUTime

float

Exponential moving average per slice, in milliseconds.

sliceInDataSize, sliceOutDataSize

float

Moving average of bytes to and from the worker per slice.

sliceCPUDensity, sliceGPUDensity

float

Moving average of the fraction of wall-clock time spent on the CPU or GPU. Wall time per slice is sliceCPUTime / sliceCPUDensity.

taskDistribution

float

Moving average of the fraction of a task’s nominal duration this job’s slices took, on requests where the job was eligible. Long slices can exceed 1.

*_variance

float

Exponential moving variance of each average above. The square root is a usable standard deviation.

totalCPUTime, totalGPUTime

int53

Running totals, in milliseconds.

totalInDataSize, totalOutDataSize

int53

Running totals, in bytes.

The moving averages use alpha = min(0.5, unreported ÷ total), so a small job’s averages move quickly and a large job’s settle.

jobFinData

One row per job, keyed by id = jobs.id. Read by the job owner. sliceWorkPaymentTotal is DCC paid out so far; sliceWorkPaymentPending is DCC held in escrow for distributed, unfinished slices. The row is recalculated when the job is paused or finished.

Note

Known issue as of 2026-10-03, expected to change: this table returned no row for finished, paid jobs in testing. Treat it as advisory and fall back to offer × completed slices when it’s empty.

activeSlices

Slices that have been handed out and have no result yet. Read by the job owner. Not authoritative for payment; the worker columns record the most recent assignment and aren’t guaranteed.

Column

Type

Meaning

jobId, sliceNumber

id, integer

Which slice.

status

string

new (created, not sent), scheduled (sent), working, overdue (the watchdog thinks it’s late), returned (given back, nobody working on it), tiebreaker, paused.

beginTime

timestamp

When the last assigned worker started it.

lastProgressTime

timestamp

Activation time or the last progress() report. Workers must report progress at least every 5 minutes.

retaskCounter

integer

How many times the slice has been marked overdue.

lastAssignedWorker

opaqueId

Worker id most recently given the slice.

lastAssignedWorkerIdentity

ethAddress

That worker’s identity.

jobResults

One row per completed slice. Read by the job owner; value can be changed (for example to move a result to new storage). value is a URI: a data: URI holding the result for small results, or a URL into the result store on the scheduler for large ones. As of 2026-10-03 the table has no timestamp column, so completion over time has to be sampled by the caller.

Column

Type

Meaning

jobId

id

jobs.id.

sliceNumber

integer

Slice index, from 1.

value

URI

The result, see above.

count({ table: 'jobResults', prototype: { jobId } }) is the number of finished slices.

jobData, jobArguments, workFunctions

The job’s inputs. All read by the job owner; value is changeable on jobData and jobArguments (for example to point a slice that hasn’t started at a new remote URI). workFunctions is read-only.

Table

Columns

jobData

jobId, sliceNumber, value (URI): one input datum per slice.

jobArguments

jobId, argIndex, value (URI): the shared arguments passed to every slice.

workFunctions

jobId, value (URI: the stringified work function or a URL to it), requirePath, modulePath, dependencies (json).

workRejectHistory

One row each time a worker rejected the job outright, for example by calling work.reject() or because a requirement couldn’t be met. Read by the job owner.

Column

Type

Meaning

jobId

id

jobs.id.

sliceNumber

integer

The slice that triggered the rejection.

worker

opaqueId

Which worker.

time

timestamp

When.

reason

string

Short reason, for example EWORKREJECT.

errorMsg

string

The message or the top of the stack.

retries

integer

Retries the worker allowed before rejecting.

computeGroupsJobs_byJob

The computeGroupJobs membership table seen from the job side: jobId, computeGroupId, lastUpdate. Read by the job owner. It gives the numeric ids of the groups the job is in; resolving them to names needs the group’s opaqueId, which this view doesn’t carry.

Compute Groups

All of these are read by the Compute Group owner, through computeGroups.owner.

computeGroups

Column

Type

Meaning

opaqueId

opaqueId

Public group id.

owner

ethAddress

Group owner; has elevated permissions.

name, description

string

Changeable by the owner.

joinKey, joinHash, joinAddress

string

Join credentials: a login, a seeded hash of the secret, and an address whose signature is an alternative. Changeable by the owner.

commissionRate, commissionAccount

finNum, ethAddress

Fraction of each slice payment taken as commission, and where it goes.

deployFee, addJobFee

finNum

DCC charged per deployment and per job added.

deployAccess

string

owner or join: who may deploy into the group.

maxTotalPayment, maxConcurrentJobs, maxConcurrentWorkers, maxConcurrentSandboxes, maxConcurrentCPUs, maxConcurrentGPUs, maxConcurrentEscrow

finNum, integer

Administrative limits; null means unlimited.

creationTime, lastUpdate

timestamp

When the group was created and last changed.

computeGroups_public

Readable by anyone: opaqueId, name and description, filterable only on opaqueId. As with jobs_public, an empty prototype lists every group as of 2026-10-03.

computeGroupJobs

Membership: computeGroupId, jobId, lastUpdate. Read by the group owner.

computeGroupAccountingData

Remaining budgets per group: remainingCPUTime, remainingGPUTime, remainingJobs, remainingInDataSize, remainingOutDataSize.

computeGroupWorkerOrigins

URL origins that workers in the group may contact, with type one of any, fetchWorkFunctions, fetchArguments, fetchData, sendResults. The owner can add, change and delete rows.

computeGroupJobPeriodStats

Per group, per job, per period. This is the only table that records what actually happened in a group over time, and the basis for any market-rate figure.

Column

Type

Meaning

computeGroupId, jobId

id

Which group and which job.

periodStart, periodLength

int53

Period start in seconds since the epoch, and its length in seconds.

taskEligibleCount

int53

Task requests from eligible workers.

noSliceTaskCount

int53

Of those, requests that got no slice of this job.

taskedSliceCount

int53

Slices handed out.

totalEarnings

finNum

DCC earned by the group’s workers on this job in the period.

totalCPUTime, totalGPUTime, totalInDataSize, totalOutDataSize

int53

Totals for the period (milliseconds, bytes).

slice* and slice*_variance

float

Per-slice moving averages and variances, as in jobPerfData, scoped to this group.

totalEarnings ÷ totalCPUTime is the realised rate per CPU-millisecond for that job in that group and period. The cgstat tool on the scheduler host dumps, summarizes and compacts these rows.

computeGroupWorkerPeriodStats

Reserved. As of 2026-10-03 only computeGroupId, workerOpaqueId, periodStart and periodLength exist; per-worker supply statistics are planned here.

Workers

Read and changed by the worker’s registered owner. The tables prefixed w$ and cc$ in the policy are the restricted views a worker’s own proxy key uses; an owner’s key uses the names without the prefix.

worker

Registration: opaqueId (public worker id), owner, identity (the worker’s local key), label (usually the host name), transferLock (true means it can’t be re-registered to another owner), flags (bit 0 marks a Portal worker). The owner has full access.

workerRunInfo

Written at every worker start and on config changes. One row per worker.

Column

Type

Meaning

workerOpaqueId, owner

opaqueId, ethAddress

Which worker and whose it is.

type, os, arch, version, browser, browserVersion

string, json

What’s running: browser or dcp-worker, platform, versions.

hostname, username, localIpAddress, macAddress, pid

string

Host identification.

cpuType, cpuCores, gpuType, gpuCores, ram

string, float

Hardware. ram is in MB.

cpuTargetUtilization, gpuTargetUtilization, maxSandboxes

float

How much of the machine the worker will use.

earningsAccount, earnings

ethAddress, finNum

Where it’s paid and what it has earned since the last reset.

status

string

running or end.

lastStartTime, lastUpdate, lastError, lastErrorTimestamp

timestamp, json

When it last started, last changed, and its last error.

workerTaskInfo

Written on every task fetch: taskTime (last fetch), currentTask (json), serial (ring-buffer position). The averageBusySandboxes* and averageIdleSandboxes* columns exist but are marked as not to be used in the schema as of 2026-10-03.

workerSnapshot

A read-only view joining worker, workerRunInfo, workerTaskInfo and dcpWorkerAppConfig, plus a virtual running column. One query for everything about the owner’s workers.

dcpWorkerAppConfig, workerConfigValue

Worker configuration pushed from the database: application settings (syslogUrl, enableSyslog, enableEventLog, startupDelay, startupDelayType) and individual dcpConfig.worker values (keyPath, value). type is active or template; a null workerOpaqueId means the row applies to all of the owner’s workers. Owner has full access.

workerCreds, credsList, credential

Credential storage for workers, currently compute-group join credentials (type cg-join on the list, cg on the credential, with identifier holding the joinKey and secret the joinHash). Owner has full access. Workers read them through a credCookie.

workerNotifications, registerWorkerDirective

Notifications queued for a worker (event, signature) and instructions for worker registration keys. Owner has full access.

Not exposed

consensusResults, reliableEvents, the vw_* views and the check test table have no policy and can’t be queried: the error is Invalid operation scheduler.jnu.<table>.query.