Documentation

Overview

Use the service

Billing

Reference

Use the service

Analytical jobs

Run a linux/amd64 container image with the CPU and memory you choose, follow it through its phases and read its output.

Images

Jobs run images from repositories admitted on the grid's registry, registry.grid.zyxio.xyz; ask us to admit yours. You may name a tag or a digest. The grid resolves it to a digest when you submit, and every attempt runs exactly that digest (imageDigest in the answer).

What you ask for

FieldMeaningBounds
command, argsWhat to run; command replaces the image's entry point.up to 128 items each
resources.cpurequest and limit, as 500m or 2.250m to 8
resources.memoryrequest and limit, as 512Mi or 4Gi.256Mi to 16Gi
resources.ephemeralStorageScratch disk, request and limit.256Mi to 32Gi
runningDeadlineSecondsThe longest one attempt may run.1 to 21,600 (six hours)
retriesAutomatic replays of an attempt we lose to a machine that ran short of resources (PLATFORM_EVICTED). Any other ending is final; retry it yourself if you want.0 to 3; default 0
priorityHigher runs sooner.0 to 10; default 0
capabilities.networkProfilenone, or public-https for HTTPS to the public internet. Internal addresses are never reachable.
envEnvironment variables. Names starting AWS_, AZURE_, BROWSERGRID_, COMPUTE_ or GOOGLE_, and a few system names, are reserved.up to 100
labelsLower-case key and value pairs you can filter GET /jobs by.up to 20
idempotencyKeyYour name for this submission. Sending the same key with the same body again returns the existing job instead of a new one.1 to 128 characters

env, labels, capabilities and idempotencyKey are required; {} is fine for the first two.

Phases

ACCEPTED → QUEUED → PROVISIONING → RUNNING → PUBLISHING → SUCCEEDED, FAILED, TIMED_OUT or CANCELLED.

A finished attempt has a termination with a class and a reason. The class says how the grid treats the attempt (whether it retries it), the reason says what happened, and the reason decides what you pay:

ReasonClassWhat happenedBilled
WORKLOAD_SUCCEEDEDworkloadYour container exited with code 0.yes
WORKLOAD_FAILEDworkloadYour container exited with another code.yes
PLATFORM_OOMplatformYour container used more memory than its own resources.memory.limit and was stopped.yes
RUNNING_DEADLINE_EXCEEDEDplatformIt was still running when your runningDeadlineSeconds ran out, and was stopped.yes, up to the deadline
CANCELLEDcancelledYou cancelled it.yes, for the time it ran
PLATFORM_EVICTEDplatformWe moved it off a machine that ran short of resources; it is retried automatically while retries allow.no
PLATFORM_STORAGE_EXCEEDEDplatformThe machine it ran on ran short of disk.no
PLATFORM_IMAGE_ERRORplatformThe image could not be pulled or started.no
PLATFORM_PROVISION_TIMEOUTplatformIt did not start in time.no
PLATFORM_INTERNALplatformThe grid lost the attempt.no

Output

Write results to stdout or stderr. After each attempt the grid publishes its output as one text log, up to 1 MiB; GET /jobs/{jobId}/logs returns it, and the x-browsergrid-logs-truncated header says whether the cap was reached.

What it costs

€0.04 per vCPU-hour plus €0.0064 per GiB-hour, accrued per millisecond, on the CPU and memory you request.

  • At submission the job reserves one attempt's longest cost: (vCPU × €0.04 + GiB × €0.0064) per hour × runningDeadlineSeconds, whatever retries you set.
  • Each attempt is charged from the moment its container starts until it finishes, never beyond runningDeadlineSeconds, when its reason is billed in the table above: your code's own exit, your own memory limit, your own deadline or your cancellation. Queueing and start-up are free.
  • Failures on our side are free: every other reason costs nothing, and a replay we make after one is never charged twice.
  • At most one attempt is billed per submission, so one attempt is all it holds. A replay follows only an eviction, which is free, and every billed reason ends the job: the attempts before the billed one leave the reservation untouched, and the billed one is charged against it, never more. retries changes neither what is held nor what a submission can cost.
  • A manual retry (POST /jobs/{jobId}/retry) is a new submission: it reserves one attempt's longest cost again and, with credit enforcement on, can be refused with 402.
  • Resubmitting the same idempotencyKey returns the existing job and reserves nothing.
  • When it shows: attempts are settled by a periodic pass over the grid's records, so the charge, and the release of what the job did not use, appears up to one settlement interval (30 seconds) after an attempt or the job finishes.

A 2 vCPU, 4 GiB job that runs 10 minutes costs €0.0176. See Pricing units.

Reference

POST /jobs, GET /jobs, GET /jobs/{jobId}, POST /jobs/{jobId}/cancel, POST /jobs/{jobId}/retry, GET /jobs/{jobId}/logs, GET /jobs/{jobId}/artifacts.