Skip to main content
skill CX Codex

stress-testing — Claude Code skill: find breaking points under load

A skill for stress testing: push a system past normal capacity to find breaking points, check auto-scaling and recovery after overload.

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add aj-geddes/useful-ai-prompts --skill stress-testing -a claude-code
Open on GitHub

What stress-testing does

This skill lays out how to push a system beyond its usual load and watch where it gives up. It covers progressive load increase, measurements, and what happens after the spike is removed. Useful when you need to know the capacity limit before touching the architecture.

The quick start is a k6 script in JavaScript: stages ramp virtual users up, thresholds watch response time and error rate. Alongside it sit reference guides on k6, spike testing, soak testing, JMeter, auto-scaling validation and breaking point analysis. So it is a set of scenarios for different kinds of overload, not a single command.

The skill says plainly not to run this against production without safeguards. Another thing: do not expect linear scaling. The database or a third-party service will hit its ceiling before the app does, so the checklist tracks memory, leaks and external dependencies.

What it helps with

  • find the load level where a service starts returning errors
  • check how auto-scaling reacts to a sudden traffic jump
  • see whether the system recovers after the load is removed
  • measure behaviour during a short spike of requests
  • verify error handling and graceful degradation under load

Example prompts for the agent

  • run a stress test against this API and show me where errors start
  • build a k6 scenario with load stages and p99 thresholds
  • check how the system behaves after a traffic spike

How to install stress-testing

1Skills CLI (Vercel)

npx skills add aj-geddes/useful-ai-prompts --skill stress-testing -a claude-code

2Manually: put the files in place

~/.claude/skills/stress-testing/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/stress-testing/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about stress-testing

How do I install stress-testing in Claude?

Run npx skills add aj-geddes/useful-ai-prompts --skill stress-testing -a claude-code. The skill lands in ~/.claude/skills/stress-testing/SKILL.md.

What does stress-testing do?

It describes stress testing a system: raising load above normal, finding breaking points, checking auto-scaling and recovery. Inside are k6 examples and guides for different overload scenarios.

What are the examples built on?

The quick start is a k6 script importing k6/http and k6/metrics, with load stages and thresholds for response time and errors. Separate guides cover JMeter, soak tests and more.

Source text

SKILL.md · MIT
---
name: stress-testing
description: >
  Test system behavior under extreme load conditions to identify breaking
  points, capacity limits, and failure modes. Use for stress test, capacity
  testing, breaking point analysis, spike test, and system limits validation.
---

# Stress Testing

## Table of Contents

- [Overview](#overview)
- [When to Use](#when-to-use)
- [Quick Start](#quick-start)
- [Reference Guides](#reference-guides)
- [Best Practices](#best-practices)

## Overview

Stress testing pushes systems beyond normal operating capacity to identify breaking points, failure modes, and recovery behavior. It validates system stability under extreme conditions and helps determine maximum capacity before degradation or failure.

## When to Use

- Finding system capacity limits
- Identifying breaking points
- Testing auto-scaling behavior
- Validating error handling under load
- Testing recovery after failures
- Planning capacity requirements
- Verifying graceful degradation
- Testing spike traffic handling

## Quick Start

Minimal working example:

```javascript
// stress-test.js
import http from "k6/http";
import { check, sleep } from "k6";
import { Rate } from "k6/metrics";

const errorRate = new Rate("errors");

export const options = {
  stages: [
    // Stress testing: Progressive load increase
    { duration: "2m", target: 100 }, // Normal load
    { duration: "5m", target: 100 }, // Sustain normal
    { duration: "2m", target: 200 }, // Above normal
    { duration: "5m", target: 200 }, // Sustain above normal
    { duration: "2m", target: 300 }, // Breaking point approaching
    { duration: "5m", target: 300 }, // Sustain high load
    { duration: "2m", target: 400 }, // Beyond capacity
    { duration: "5m", target: 400 }, // System under stress
    { duration: "5m", target: 0 }, // Gradual recovery
  ],
  thresholds: {
    http_req_duration: ["p(99)<1000"], // 99% under 1s during stress
    http_req_failed: ["rate<0.05"], // Allow 5% error rate under stress
    errors: ["rate<0.1"],
  },
// ... (see reference guides for full implementation)
```

## Reference Guides

Detailed implementations in the `references/` directory:

| Guide | Contents |
|---|---|
| [k6 Stress Testing](references/k6-stress-testing.md) | k6 Stress Testing |
| [Spike Testing](references/spike-testing.md) | Spike Testing |
| [Soak/Endurance Testing](references/soakendurance-testing.md) | Soak/Endurance Testing |
| [JMeter Stress Test](references/jmeter-stress-test.md) | JMeter Stress Test |
| [Auto-Scaling Validation](references/auto-scaling-validation.md) | Auto-Scaling Validation |
| [Breaking Point Analysis](references/breaking-point-analysis.md) | Breaking Point Analysis |

## Best Practices

### ✅ DO

- Test in production-like environment
- Monitor all system resources
- Gradually increase load to find limits
- Test recovery after stress
- Document breaking points
- Test auto-scaling behavior
- Plan for graceful degradation
- Monitor for memory leaks

### ❌ DON'T

- Test in production without safeguards
- Skip recovery testing
- Ignore warning signs (CPU, memory)
- Test only success scenarios
- Assume linear scalability
- Forget database capacity
- Skip monitoring third-party dependencies
- Test without proper cleanup

© aj-geddes · MIT · aj-geddes/useful-ai-prompts

Similar skills

Everything for Testing and QA →

From the same set118

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor