Agents
This screen is where you attach CoverOps to running code and watch it report. It shows every replica that is reporting right now, how much of each service's traffic the tracer could watch, a step-by-step setup for each runtime, the settings you can push to running agents, and the list of agent registrations with their tokens.
Where to find it
Sidebar → Workspace → Agents. The screen always works on the active project.
- Everyone with access to the project can see it.
- Registering an agent, rotating or deleting a token, changing server-side agent settings and the source-upload policy need a role that can change the project: a viewer (read-only) account or a project viewer seat is refused.
- Organisation-wide can only be changed by the account owner of the project the token belongs to. Everyone else sees the checkbox disabled, with a tooltip saying only the account owner can change it; the server refuses the change for them.
What it shows
Live fleet
Every replica reporting into this project. Each pod or host of a service is its own row. The panel header shows how many are up and how many were seen.
The section opens folded: you see one line of cards, All plus one card per runtime (Java, Node.js, .NET, Go, PHP, Python, Ruby, Android, iOS) with its up / total count. Click a card to open the table filtered to that runtime; click it again to fold it.
When open, the toolbar has:
- a filter box (Filter by service, pod, IP or environment…),
- Only up,
- grouping: By service (default), By env, By lang, Flat.
Groups are ordered busiest first and can be folded by clicking their header, which shows up / total. Within a group, live rows come first, then the most recently heard from.
Columns: Status (up or idle), Service · pod, Language, Environment, IP, Version (the build the process announced at start-up; pre-versioning for agents too old to say), Last report.
Trace sampling · 7 days
Shown only when there is sampling data. One row per service: Requests, Watched (share and count of requests whose code was recorded), Routes, and Never watched. When a service has routes that were never watched, click the number to list them with their hop counts.
1 · What are you measuring?
Runtime tiles: Java, Node.js, .NET Core, .NET Framework, Go, Python, PHP, Ruby, Android, iOS. The two mobile tiles are app-code coverage: a collector in a test build of the app and a command on the build host; see Mobile app coverage. A mobile row on the fleet is an upload, not a running process, so it shows as idle a minute and a half after the command finished.
C and C++ have no tile: their coverage comes from the compiler (gcc --coverage or clang source-based coverage). Set them up from the C / C++ coverage card on Integrations: link libcoverageops into the service, then run coverageops cc-upload --watch beside it, or once in CI. See agents/cpp/README.md. The token is an ordinary agent token from this page.
2 · How does it attach?
The ways the chosen runtime can be attached. Choosing one shows a ready-to-copy example.
| Runtime | Methods |
|---|---|
| Java | JVM flag, Spring Boot, Maven, Gradle, Tomcat, Docker, Kubernetes, Guided install (CLI), K8s auto-attach, GitHub Actions, Jenkins, GitLab CI |
| Node.js | node --require, NODE_OPTIONS, Docker, ECS / Fargate, Kubernetes, Guided install (CLI), K8s auto-attach, GitHub Actions, Jenkins, GitLab CI |
| .NET Core | Publish + instrument, Docker, GitHub Actions, Jenkins, GitLab CI |
| .NET Framework | Build + instrument, web.config (tests + traces), IIS app pool, Azure Pipelines |
| Go | Build flag + import, Traces & attribution |
| Python | Per-test lines & call chains (one line), python -m runner, Import preload, Docker, GitHub Actions |
| PHP | php.ini / FPM, Built-in server (php -S) |
| Ruby | Rails (Gemfile), Rack (Sinatra, Hanami, Roda), Puma / Unicorn workers |
Around the example:
- Download agent with the package type: Java
.jar, Node.js.tgz, Python.tar.gz, .NET Core and .NET Framework.nupkg(one package with both builds), Gosource .tar.gz, PHP.php, Ruby.gem(the RSpec and minitest gems are on the Integrations page). - Copy example.
- A note on naming: the service name is detected (for example
spring.application.name,OTEL_SERVICE_NAME,package.json, the entry assembly) and the agent logs which source it used. - For Java, Node.js, .NET Core, .NET Framework, Python and Ruby, a Recommended configuration table: the settings that are most often set wrong, the value to use, and what goes wrong otherwise.
- Privacy, verification & troubleshooting: what the agent sends, how to verify it, and what to check when nothing shows up.
3 · Register it
Name, Environment (suggestions: ci, local, staging, prod; any value is allowed) and Create & mint token.
Test automation integrations
A pointer to the Integrations screen, where the test-runner integrations (Selenium / JUnit 5, Playwright, Cypress and others) live.
Access token box
Appears after you register an agent or rotate a token: Access token for … (shown only once), the token, the chosen setup with the token filled in, and Copy token, Copy command, Close.
Server-side agent settings
Tracing (as started / on / off), Sample 1 in N requests, Flush interval (s), Log level (off, error, warn, info, debug), Save, Clear overrides, then Source code storage — Store source or Metadata only — with, under Store source, the Accept source uploads (pause without deleting) checkbox and, under Metadata only, Show code from the connected repository when a file is opened (never stored).
Registrations
The last panel lists every registered agent of the project. The header counts how many are tracking and how many are registered. Each row shows a status badge, the name, language · environment, last seen, the Organisation-wide checkbox, Rotate token and Delete. Under a row, chips show each service reporting on that token in the currently open monitoring window, with how long ago it last reported.
How it works
- Up and idle (Live fleet). A replica is up when it reported within the last 90 seconds; otherwise it is idle. Replicas that have not reported for 7 days drop off the list. The list holds at most the 500 most recently seen replicas and refreshes every 5 seconds.
- Replicas. Each agent sends the replica it runs as (
COVERAGEOPS_INSTANCE, by default the host name, which in Kubernetes is the pod name). Five pods of one service are five rows grouped under the service. - When CoverOps is unreachable or busy. An agent sends again what got a 5xx, 408 or 429, timed out or could not connect: after the server's
Retry-After(at most 60 s), else after a growing random wait (0.1 s up to 30 s), at most 5 tries and 30 s per upload, always on the agent's own thread — never on the application's. Nothing is lost while it lasts, up to a bound: coverage is cumulative and goes whole on the next cycle, traces wait in a queue of 1,000 (COVERAGEOPS_TRACE_QUEUE) and per-test lines in one of 10,000 entries (COVERAGEOPS_TEST_QUEUE); past that the oldest go, with one warning per outage. Each trace carries an id, so one sent twice is stored once. When a monitoring window opens or closes, the run being left gets 30 s of retries for its last data. At shutdown the last flush gets at most 10 s in all (COVERAGEOPS_SHUTDOWN_FLUSH_SECONDS), so a service never hangs on the way down; the Go agent does it incoverageops.Stop(), which the application defers. The PHP agent never waits inside a request: it holds the route and a later request sends what waited in its spool. Refusals (401,402,403,413) are not retried and behave as before. The numbers are in the ingest protocol. - Tracking (Registrations). A registration is tracking when the agent reported within the last 2 minutes, idle after that, and never seen if it has never reported. The list refreshes every 10 seconds. A service chip is green when that service reported within the last 15 minutes.
- Snippets are filled with this installation's API address:
https://api.coverops.aion the hosted service, otherwise the address you opened the dashboard on. Until you register an agent the token shows as<AGENT_TOKEN>; after registering or rotating, every snippet on the page carries the new token. All processes started with the samerunKeymerge into one run. An open monitoring window overrides it; when the window is stopped, every agent goes back to its own run key on its next poll (see Concepts for where that key comes from). - Registering creates the agent and its first token together. The name may contain only letters, digits, dot, dash and underscore (up to 120 characters) and must be unique in the project. The environment can be up to 60 characters.
- Production environments. An environment starting with
prod,production,prdorliveneeds a package that includes production monitoring. Without it, registration is refused straight away, and reports from such an agent are refused too. - The token is shown once. Only a hash is stored. If you lose it, rotate.
- Rotate token revokes every live token of that agent and issues a new one in the same step. Processes still using the old token get
401and stop reporting until restarted with the new one. - Delete first asks Delete this agent?, naming the agent and saying its token stops working immediately: every process still using it is refused from its next report. It cannot be undone; a new agent gets a new token.
- Server-side settings are saved for the whole project and applied by every agent on its next poll, within one flush interval, without a restart. An empty field means "leave it as the agent was started". Clear overrides removes them all. Turning tracing on only works for agents that started with tracing woven in. Allowed ranges: sample 1–10,000, flush interval 5–3,600 seconds.
- Source code storage. Store source keeps the text of covered files, as agents upload it or a connected repository supplies it; every feature works. Metadata only means CoverOps never stores the code: agents and the CLI send a source outline instead — per file the line count, which lines are code, comment or blank, a fingerprint per line and the method ranges — and the text of a file upload is refused with
403 SOURCE_METADATA_ONLY. New projects on the hosted service start with Metadata only; on a self-hosted install they start with Store source (COVEROPS_SOURCE_STORAGE_DEFAULTchanges either). Existing projects keep what they had. - Who can change it. Only the project owner or an admin member. Switching to Metadata only permanently deletes the project's stored source files and the code map built from them; with files stored, the page asks you to type
deletefirst. The change, and how many files were deleted, is recorded in the Audit log — never a path or a line. - What metadata only changes. The file view shows line numbers, coverage and line kinds without the code, and offers Open local copy…: the file you pick stays in the browser, and only its line fingerprints are sent to check it is the version that was measured (differing lines are marked). With Show code from the connected repository… on, a file is read from the repository for that one view and kept nowhere. The code map is not built. Line exclusion rules, line-level test selection and static call edges need the outline from
coverageops outline(agents alone do not compute them); a run says how many files its line rules could not reach. Seedocs/design/no-source-mode.mdfor every feature. - How the fingerprints are protected. Each agent sends a short SHA-256 of every line (whitespace-normalised); the server re-keys it with a per-project key (HMAC, the key sealed with the installation's secrets key) and stores only that. A database dump or backup alone cannot be tested against guessed lines. The running service could test guesses, so a line anyone can guess (
},return null;) is not secret — a line with real logic is not recoverable without guessing it exactly. - Agents. Java, Node and Ruby agents send outlines in a metadata-only project (Ruby's with method ranges parsed from the source), and send nothing about source until their first poll has said which the project wants. Python, Go, .NET and PHP agents send no outlines yet; their source upload is refused and coverage keeps working. An agent older than this change offers source once per process start; it is refused and not stored. To avoid even that, start such agents with
COVERAGEOPS_SOURCE=offor upgrade them. - Accept source uploads (pause without deleting). Under Store source only. Off refuses uploads with
403, coverage keeps flowing, and files not yet stored show line numbers. Files uploaded earlier stay; for a guarantee that no code is kept, choose Metadata only. - Session replay link. It moved to Integrations → ReplayOps: Connect with ReplayOps sets up both directions, and the token and URL template by hand are under its Advanced section.
- Organisation-wide lets the account's other projects include the services reporting with this token (see Projects). Turning it off removes the services from every project that included them.
What you can do
| Action | Effect |
|---|---|
| Click a runtime card, filter, group, fold | Changes the fleet view only |
| Download agent | Downloads the agent package for the runtime |
| Copy example, Copy command, Copy token | Copies to the clipboard |
| Create & mint token | Registers an agent and shows its token once |
| Rotate token | Revokes the old token and shows a new one once |
| Delete | After you confirm, deletes the registration and revokes its token |
| Organisation-wide | Shares or stops sharing the token's services with the account's other projects (owner only) |
| Save / Clear overrides | Pushes or removes server-side agent settings |
| Store source / Metadata only | Chooses what the project keeps of its code; to metadata only, after you type delete, deletes the stored source (owner or admin) |
| Show code from the connected repository… | In metadata only: reads a file from the repository when it is opened, never stores it |
| Accept source uploads | In store mode: pauses or resumes source uploads without deleting anything |
| Issue / Revoke (replay token) | Creates or revokes a read-only token for a replay tool |
| Save (replay URL) | Stores the session URL template |
Creating, rotating and deleting agents, sharing changes, setting changes, source-upload policy changes and source code storage changes are recorded in the Audit log.
Limits and good to know
- C and C++ processes report with runtime
cpp(c++,cxxandcare read the same way). The fleet, its By lang view and the run's service cards show them as C/C++. Their per-test lines come from aTestScopein your request handler, because C++ has no standard HTTP stack for the agent to hook into (agents/cpp/README.md). - Two different status rules are in play: the fleet uses 90 seconds per replica, the registration list uses 2 minutes per token.
- An agent also works inside a test process, for unit tests: the Java agent on the test JVM (
-javaagentin Surefire'sargLine), the .NET agent on the test host (DOTNET_STARTUP_HOOKSondotnet test, the code under test woven) and the Go agent'scoverageopstestin a test binary built with-cover -covermode=atomicrecord which lines each test ran (an in-process footprint). See In-process tests. A test JVM or test host reports like any agent, as the service it names (coverageops.service,COVERAGEOPS_SERVICE). - Service chips under a registration only appear while a monitoring window is open.