agentleFS
kienbui1995kienbui1995/magic-powers/skills/performance-testing/SKILL.md

performance-testing

Skill0 starsChanged 8 months agoMITView on GitHub

Use when load testing APIs, profiling bottlenecks, or validating performance SLAs before release

8 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use security-testing and api-testing.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • mmondoraSkill

    security-testing

    Automated security testing in CI. SAST, DAST, dependency scanning, authorization testing, secret detection. Use when adding security scans to pipelines, writing tenant isolation tests, or configuring vulnerability scanning.

    Also in 3 projects that use this

  • aiqualitylabSkill

    api-testing

    Generate and run REST API tests using Postman collections and Newman CLI. Use when asked to test APIs, verify endpoints, validate responses, or run Postman tests in CI.

    Also in 3 projects that use this

The file

We split this skill into the rules it gives an agent

4 rules. 0 are common, 4 are distinctive, and 0 are very specific to this project.

  • 0

    Common

    Most of the 7 edited versions we read keep these.

  • 4

    Distinctive

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    When you need to validate that a system can handle expected load, find bottlenecks before users do, or establish performance baselines.

    line 9
  2. Distinctive:

    Use APM (Datadog, New Relic) to find slow traces

    line 57
  3. Distinctive:

    Test results report (percentile breakdown)

    line 65
  4. Distinctive:

    No profiling when tests fail — "we need more servers" is rarely the fix

    line 71

“Common” is measured: kept by at least 6 in 10 of the 7 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Performance Testing

When to Use

When you need to validate that a system can handle expected load, find bottlenecks before users do, or establish performance baselines.

Core Jobs

1. Define Performance Requirements

Before testing, specify:

  • Throughput target: X requests/sec at peak
  • Latency target: P95 < Nms, P99 < Nms
  • Error rate target: < X% under load
  • Duration: how long must it sustain this load?

Without these, you don't know if your test passed.

2. Write Load Test Scripts

k6 example:

import http from 'k6/http';
import { check, sleep } from 'k6';

export const options = {
  stages: [
    { duration: '2m', target: 50 },   // ramp up to 50 users
    { duration: '5m', target: 50 },   // stay at 50
    { duration: '2m', target: 100 },  // ramp to 100
    { duration: '5m', target: 100 },  // stay at 100
    { duration: '2m', target: 0 },    // ramp down
  ],
};

export default function () {
  const res = http.get('https://api.example.com/users');
  check(res, { 'status was 200': (r) => r.status === 200 });
  sleep(1);
}

3. Run and Observe

During the test, watch:

  • Latency trend (is it flat or climbing?)
  • Error rate
  • CPU and memory on the server
  • Database connection pool utilization
  • Queue depths (if async)

The throughput "knee" = where latency starts degrading rapidly. Don't target above this.

4. Profile and Fix Bottlenecks

When tests fail:

  • Use APM (Datadog, New Relic) to find slow traces
  • Database: check slow query log, explain plan, missing indexes
  • CPU: profile with py-spy, pprof, or async-profiler (JVM)
  • Memory: heap dump analysis

Key Outputs

  • Load test script (version controlled)
  • Performance requirements document
  • Test results report (percentile breakdown)
  • Bottleneck analysis and fixes

Anti-Patterns

  • Testing without defined pass/fail criteria
  • Testing average load only (not peak or spike)
  • No profiling when tests fail — "we need more servers" is rarely the fix
  • Running performance tests against production

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.