code
Mar 17, 2026EVAL-20260317-022129Your Node.js API is responding with 502 errors under load. Here's the relevant code and infrastructure: - Express.js API behind an Nginx reverse proxy - Connection pool to PostgreSQL (max 20 connections) - Average response time: 50ms normally, 30s+ during incidents - Error logs show: "connect ETIMEDOUT" and "too many clients already" - The issue starts when traffic exceeds 200 req/s ```javascript app.get('/api/users/:id', async (req, res) => { const client = await pool.connect(); const result = await client.query('SELECT * FROM users WHERE id = $1', [req.params.id]); res.json(result.rows[0]); }); ``` What's wrong? Provide the fix and explain the connection pool exhaustion pattern.
Winner
Qwen 3.5 35B-A3B
openrouter
9.89
WINNER SCORE
matrix avg: 9.47
10×10 Judgment Matrix · 50 judgments
OPEN DATA
| Judge ↓ / Respondent → | Qwen 3.5 9B | Qwen 3 8B | Qwen 3 32B | Qwen 3 Coder Next | Qwen 3.5 35B-A3B | Qwen 3.5 27B | Qwen 3.5 122B-A10B | Qwen 3.5 397B-A17B |
|---|---|---|---|---|---|---|---|---|
| Qwen 3.5 9B | — | 8.6 | · | 8.8 | 9.8 | 8.6 | 9.2 | 5.0 |
| Qwen 3 8B | 9.8 | — | 10.0 | 10.0 | 10.0 | 10.0 | 10.0 | 10.0 |
| Qwen 3 32B | 9.4 | 9.6 | — | 9.6 | 10.0 | 10.0 | 9.6 | 9.6 |
| Qwen 3 Coder Next | 10.0 | 10.0 | 10.0 | — | 10.0 | 10.0 | 10.0 | 10.0 |
| Qwen 3.5 35B-A3B | · | · | 10.0 | 9.8 | — | · | 10.0 | 10.0 |
| Qwen 3.5 27B | 9.3 | 7.3 | · | 9.3 | 9.6 | — | 9.6 | 9.6 |
| Qwen 3.5 122B-A10B | 8.2 | 8.0 | 8.8 | 9.6 | 9.8 | 9.0 | — | 9.6 |
| Qwen 3.5 397B-A17B | 9.3 | 9.3 | · | 10.0 | 10.0 | 9.6 | 10.0 | — |