- Add MAX_CONCURRENT_AGENTS (default: 3) to limit concurrent agents - Implement acquire_agent_slot() and release_agent_slot() with flock - Wrap cmd_start, cmd_continue, and cmd_delegate with slot management - cmd_delegate holds slot until background task completes (fire-and-forget + blocking) - Add basic concurrency tests to test suite
795 B
795 B
Parallel Capacity Test Report
Generated: 2026-03-31 04:07:51
Summary
| Agents | Duration | Success | Failed | Timeout | Avg Response | Peak Mem (MB) | Mem/Agent | Cost Score |
|---|---|---|---|---|---|---|---|---|
| 1 | 1.0s | 0 | 1 | 0 | 0.0s | 2461MB | 1.9MB | 0.00 |
| 2 | 1.0s | 0 | 2 | 0 | 0.0s | 2464MB | 0.5MB | 0.00 |
| 3 | 1.0s | 0 | 3 | 0 | 0.0s | 2444MB | 0.1MB | 0.00 |
Cost Analysis
| Metric | Value |
|---|---|
| Baseline Memory | 2458.8 MB |
| Avg Memory per Agent | 0.8 MB |
| Memory Limit | 1024 MB |
| Estimated Max Capacity | 1241 agents |
Key Findings
Recommendations
- Monitor closely: 5+ agents
- Implement circuit breaker when failure rate exceeds threshold