|
1 | | -# Rinha de Backend 2024/Q1 — Rust Implementation |
| 1 | +# Rinha de Backend 2024/Q1 — Rust Implementation Agent Guide |
2 | 2 |
|
3 | 3 | High-performance banking API built with Rust/Actix-web for the Rinha de Backend challenge. Handles concurrent transactions under strict resource constraints (1.5 CPU, 550MB RAM). |
4 | 4 |
|
| 5 | +This repository uses the standardized `AGENTS.md` + `.agents/` agent-instrumentation layout. Do not recreate legacy tool-specific instruction files. |
| 6 | + |
5 | 7 | --- |
6 | 8 |
|
7 | 9 | ## Tech Stack |
8 | 10 |
|
9 | 11 | | Technology | Purpose | |
10 | 12 | |-----------|---------| |
11 | | -| Rust 1.94 | Language | |
| 13 | +| Rust 1.95 builder / Cargo edition 2024 | Language | |
12 | 14 | | Actix-web 4 | Async HTTP framework | |
13 | 15 | | SQLx 0.8 | Compile-time checked PostgreSQL queries | |
14 | 16 | | PostgreSQL 16.7 | Database with stored procedures | |
@@ -40,7 +42,7 @@ NGINX (:9999, least_conn) |
40 | 42 | └── GetSaldoClienteById() — statement with JSONB aggregation |
41 | 43 | ``` |
42 | 44 |
|
43 | | -**Single-file API** (~140 lines in `src/WebApi/main.rs`). All business logic in PostgreSQL stored procedures. |
| 45 | +**Single-file API** (173 total lines in `src/WebApi/main.rs`). All business logic in PostgreSQL stored procedures. |
44 | 46 |
|
45 | 47 | --- |
46 | 48 |
|
@@ -80,9 +82,9 @@ NGINX (:9999, least_conn) |
80 | 82 | ``` |
81 | 83 | rinha2-back-end-rust/ |
82 | 84 | ├── src/WebApi/ |
83 | | -│ ├── main.rs # Complete API (~140 lines) |
| 85 | +│ ├── main.rs # Complete API (173 total lines) |
84 | 86 | │ ├── Cargo.toml # Dependencies |
85 | | -│ ├── Dockerfile # Multi-stage: rust:1.94 → debian:bookworm-slim |
| 87 | +│ ├── Dockerfile # Multi-stage: rust:1.95 → debian:bookworm-slim |
86 | 88 | │ └── .sqlx/ # SQLx offline query cache |
87 | 89 | ├── docker-entrypoint-initdb.d/ |
88 | 90 | │ └── rinha.dump.sql # Schema + stored procedures + seed data |
|
0 commit comments