Distributed agents#

An agent is JMXPress running on somebody's machine. It does two jobs: recording near the person doing it, and generating load from more than one machine.

The shape of it#

The agent dials out; the server never dials in.

That is the single most important property. There is no listening socket on anybody's laptop, no port to open, no firewall rule to ask for, and no unauthenticated endpoint on a developer machine that the rest of the office network could find.

The agent makes outbound HTTPS calls to the server and waits for work. The capture proxy it starts for recording is bound to 127.0.0.1.

Pairing a computer#

  1. On the server, open Recording or the Dashboard and choose Pair a computer. You get a pairing code.
  2. On the machine to be paired, run the agent (Start-Agent.bat on Windows) and give it the code.
  3. The agent exchanges the code for a token and appears in your list of computers.

A pairing code is single-use, short, and expires in minutes. One live code per person at a time.

The token is stored hashed on the server and compared in constant time. It can be revoked by unpairing the computer.

Note Tokens do not currently rotate on a schedule. They last until somebody unpairs the machine.

Naming a computer#

A paired computer carries the hostname it reports, and you can give it a name of your own โ€” Bo's laptop, load-gen-2 โ€” so the Run page offers something recognisable.

Generating load from several machines#

On the Run page, choose more than one computer under Where it runs.

Each agent runs the plan, and the results are brought back together. Load settings can be set per agent, so machines of different sizes can carry different shares rather than an even split that the smallest one cannot manage.

Careful The test data a plan reads is distributed with it. If every agent reads the same CSV from the top, every agent sends the same first user. Split the file, or use a dataset configuration that accounts for several machines.

What an agent needs#

  • Windows, with the agent's own requirements installed by its launcher.
  • Outbound HTTPS to the JMXPress server.
  • For load generation, a JMeter installation it can run.

Seeing what is connected#

The Dashboard shows how many of your paired computers are online, and Your computers lists them. An agent that has stopped calling in is shown as offline rather than quietly dropped.

Diagnostics#

An agent can also collect thread dumps, heap dumps and application logs โ€” but only when the machine it runs on has been configured to allow it. That is deliberately not something the server can switch on. See Heap dumps, thread dumps and logs.