Implementation
NestJS
NestJS 12.5.0 · TypeScript · Full-stack frameworks · ranked
Scores
| Category | Position | Score | ± |
|---|---|---|---|
| Hello world | 8 | 0.33* | ±27.8% |
| Database | 8–10 | 0.58* | ±21.8% |
| Application | 9–10 | 0.32* | ±20.1% |
| Memory (high-water mark) | 12 | 0.25 | ±2.2% |
| Startup | 1–13 | 0.75 | ±26.8% |
Runner CPUs: EPYC 9V45, EPYC 9V74, EPYC 9V74
Settings
- Runtime
- Node.js 26.13.1 LTS, NODE_ENV=production, compiled with nest build (tsc)
- Server
- Nest NodeAdapter (@nestjs/platform-node, on node:http)
- Workers
- node:cluster, one process per vCPU (2)
- Database layer
- TypeORM 1.1 via @nestjs/typeorm with pg, 8 connections per process (16 in total)
- Templates
- hbs 4.4 (Handlebars)
- Logging
- none per request (Nest has no request logger); start-up log per process
- Dependency source
- –
- Status
- measured
Application endpoints: mechanisms
- Validation
- ParseIntPipe for the id; ValidationPipe with class-validator DTOs for the query, the JSON body and the form: 400
- CSRF
- fetch-metadata (built-in): app.enableCsrfProtection() (Sec-Fetch-Site, then Origin against Host; 403)
- Session store
- postgresql (documented): express-session 1.19 with connect-pg-simple 10 (the documented session middleware with its PostgreSQL store), on /form, /login and /me only
Tier 1 endpoints
| Endpoint | req/s | vs Axum | Efficiency (req/CPU-s) | p99 (ms) | Errors | Limits |
|---|---|---|---|---|---|---|
| /text | 61,494 (60,403–129,425) | 0.37 | 30,765 | 3.76 | 0 | |
| /json | 55,131 (53,940–121,847) | 0.34 | 27,612 | 2.83 | 0 | |
| /db-single | 12,627 (12,214–22,738) | 0.68 | 6,737 | 21.35 | 0 | PostgreSQL-bound 15/15 |
| /html | 46,881 (45,832–104,205) | 0.29 | 23,450 | 3.16 | 0 | |
| /queries?queries=20 | 599 (572–1,000) | 0.54 | 414 | 265.05 | 0 | |
| /fortunes | 11,771 (10,721–21,579) | 0.42 | 5,891 | 34.05 | 0 | |
| GET /world/{id} | 12,107 (11,662–21,720) | 0.68 | 6,200 | 20.39 | 0 | PostgreSQL-bound 15/15 |
| GET /worlds | 8,547 (7,402–14,838) | 0.61 | 4,315 | 36.27 | 0 | PostgreSQL-bound 13/15 |
| POST /form | 13,027 (12,815–29,073) | 0.15 | 6,521 | 20.40 | 0 | |
| GET /me | 4,219 (3,927–7,538) | 0.44 | 2,600 | 47.75 | 0 | PostgreSQL-bound 15/15 |
| /updates?queries=20 | 309 (296–519) | 0.64 | 230 | 465.81 | 0 | |
| PUT /world/{id} | 3,807 (3,504–6,232) | 0.26 | 1,936 | 57.02 | 0 |
Measured versions
@nestjs/core12.5.0@nestjs/platform-node12.5.0@nestjs/typeorm12.0.3bcrypt6.0.0class-validator0.15.1connect-pg-simple10.0.0express-session1.19.0handlebars4.7.10hbs4.4.0node26.13.1pg8.23.1typeorm1.1.3
Runner jobs
| Job | CPU model | Rounds | Status |
|---|---|---|---|
| 1 | EPYC 9V45 | 5 | measured |
| 2 | EPYC 9V74 | 5 | measured |
| 3 | EPYC 9V74 | 5 | measured |