Skip to content

perf-distributed-testing

import { Aside, Steps } from ‘@astrojs/starlight/components’;

perf-distributed-testing provides Helm charts and Docker images for distributed load testing on Kubernetes — using each tool’s native distribution mechanism.

TierPrice
CommunityFree (license key registration required)
Enterprise£1,000/year (priority support SLA + named contact)

Helm charts: publicly pullable from oci://ghcr.io/markslilley/charts — no auth required.

Docker images: require license key authentication via registry.martkos-it.co.uk.

ToolDistribution Mechanism
JMeterController-Worker model via RMI
k6Stateless segment runners (index-based test splitting)
GatlingAkka actor cluster coordination
Terminal window
kubectl version --client
helm version
kubectl cluster-info # confirm cluster access
# Create namespace
kubectl create namespace perf-testing
  1. Register at martkos-it.co.uk/store/perf-distributed-testing-download

  2. Get a registry token:

    Terminal window
    TOKEN=$(curl -s https://updates.martkos-it.co.uk/api/v1/registry-token \
    -H "X-License-Key: your-license-key" \
    -H "Content-Type: application/json" \
    -d '{"product": "perf-distributed-testing"}' | jq -r '.token')
  3. Create a registry pull secret:

    Terminal window
    kubectl create secret docker-registry martkos-registry \
    --namespace perf-testing \
    --docker-server=registry.martkos-it.co.uk \
    --docker-username=token \
    --docker-password="${TOKEN}"
  1. Install the JMeter chart

    Terminal window
    helm install perf-jmeter \
    oci://ghcr.io/markslilley/charts/perf-jmeter \
    --namespace perf-testing \
    --set workers.replicas=3 \
    --set imagePullSecrets[0].name=martkos-registry
  2. Upload your test plan

    Terminal window
    kubectl create configmap jmeter-test \
    --namespace perf-testing \
    --from-file=test.jmx=my-test.jmx
  3. Run the test

    Terminal window
    kubectl exec -it deploy/perf-jmeter-controller \
    --namespace perf-testing -- \
    jmeter -n -t /tests/test.jmx \
    -JTARGET_HOST=https://api.example.com \
    -R worker-0,worker-1,worker-2
  4. Collect results

    Results are written to /results/ in the controller pod. Copy them out:

    Terminal window
    kubectl cp perf-testing/perf-jmeter-controller-xxx:/results/results.jtl ./results.jtl
jmeter-values.yaml
workers:
replicas: 5
resources:
requests:
cpu: "500m"
memory: "1Gi"
limits:
cpu: "2"
memory: "4Gi"
controller:
extraArgs:
- "-JTARGET_HOST=https://api.example.com"
- "-JVUS=1000"
securityContext:
runAsNonRoot: true
runAsUser: 1000
networkPolicy:
enabled: true
Terminal window
helm install perf-jmeter oci://ghcr.io/markslilley/charts/perf-jmeter \
--namespace perf-testing \
-f jmeter-values.yaml

k6 uses a stateless model. Each runner gets a segment of the total load:

  1. Install the k6 chart

    Terminal window
    helm install perf-k6 \
    oci://ghcr.io/markslilley/charts/perf-k6 \
    --namespace perf-testing \
    --set runners.replicas=3 \
    --set imagePullSecrets[0].name=martkos-registry
  2. Prepare your script for distributed mode

    The runners inject RUNNER_INDEX and RUNNERS_TOTAL environment variables:

    import { scenario } from 'k6/execution';
    export const options = {
    scenarios: {
    load: {
    executor: 'ramping-vus',
    startVUs: 0,
    stages: [
    { duration: '2m', target: 100 / __ENV.RUNNERS_TOTAL },
    { duration: '5m', target: 100 / __ENV.RUNNERS_TOTAL },
    ],
    },
    },
    };
    export default function () {
    // your test logic
    }
  3. Upload and run

    Terminal window
    kubectl create configmap k6-script \
    --namespace perf-testing \
    --from-file=script.js=my-script.js
    kubectl rollout restart deploy/perf-k6-runner --namespace perf-testing
k6-values.yaml
metrics:
backend: prometheus # prometheus | influxdb | cloud
prometheus:
remoteWriteUrl: http://prometheus-server:9090/api/v1/write

Gatling uses Akka actor clustering:

Terminal window
helm install perf-gatling \
oci://ghcr.io/markslilley/charts/perf-gatling \
--namespace perf-testing \
--set rbac.create=true \
--set workers.replicas=3 \
--set imagePullSecrets[0].name=martkos-registry

Upload your simulation:

Terminal window
kubectl create configmap gatling-simulation \
--namespace perf-testing \
--from-file=MySimulation.scala

All charts run containers as non-root by default:

securityContext:
runAsNonRoot: true
runAsUser: 1000
readOnlyRootFilesystem: true

Enable NetworkPolicy to restrict pod-to-pod communication:

networkPolicy:
enabled: true
Terminal window
# Pod status
kubectl get pods --namespace perf-testing
# Controller logs
kubectl logs --namespace perf-testing \
-l app.kubernetes.io/component=controller --tail=100
# Worker logs
kubectl logs --namespace perf-testing \
-l app.kubernetes.io/component=worker --tail=50
# Describe a failing pod
kubectl describe pod --namespace perf-testing <pod-name>