Skip to content
CAI
Software that uses CAICheck a score

Quentin-Piot/axum-diesel-real-world

52.6

Weak · 21 September 2026

528

lines of production code

Rust

primary language

4

measurements over time

CAI band scale
CAI trend line
CAI lens gauges

What this system is

This system is a Rust-based backend service built on the Axum framework, designed to manage a 'posts' resource. It provides a RESTful API for creating, retrieving, and listing posts, with support for filtering and pagination. The architecture follows a layered approach, separating domain models, database interactions via Diesel, and HTTP handlers, all configured through environment variables.

Features

Added post creation, retrieval, and listing handlers

The application now exposes endpoints to create, fetch, and list posts. The create\_post handler accepts a title and body to insert a new post, get\_post retrieves a single post by ID, and list\_posts returns a paginated or filtered list of all posts. These handlers utilize custom extractors for JSON and path/query parameters, mapping domain models to response structures for the API.

src/handlers, src/handlers/posts · high confidence

Introduce global configuration and structured error handling

The application now uses a centralized configuration system (src/config.rs) that loads server host/port and database URL from environment variables, replacing hardcoded values. A new error handling module (src/errors.rs) defines an AppError enum with JSON responses for internal server and bad request errors, integrating with Axum's IntoResponse. The main entry point (src/main.rs) initializes tracing, manages a database connection pool, runs migrations, and starts the Axum server using the global config. This structural change supports a more robust and configurable backend.

src · high confidence

Behavioural changes

Added database migrations for the Posts table and Diesel setup

The application now includes database migration files to initialize the schema. This includes a base migration for the Diesel ORM's internal bookkeeping and helper functions, as well as a specific migration to create the 'posts' table with fields for id, title, body, and published status.

migrations · high confidence

Introduces domain models, database schema, and repository layer for posts

This change establishes the foundational data layer for the application. It defines the PostModel domain struct and its associated error handling, alongside a Diesel-generated database schema for the 'posts' table. It also introduces a PostRepository that implements database interactions (insert, get, get\_all) with support for filtering by published status and title content. Additionally, custom request extractors for JSON and path parameters are added to the utils layer to standardize error handling for request parsing.

src/domain, src/infra, src/utils · high confidence

Dependencies

Upgrade core Rust dependencies (Axum, Diesel, Tokio)

The project's Rust dependencies have been updated to newer versions, specifically Axum 0.8.8, Diesel 2.3.6, and Tokio 1.49.0, alongside other supporting crates like chrono and serde. This update aligns the backend with current stable releases, ensuring compatibility with the latest features and security patches in the Rust ecosystem.

(dependencies) · high confidence

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

How this codebase got here

Score

  • CAI 51 → 53 (+1.7)
  • Rubric changed (rubric-2026.08.19 → rubric-2026.09.15) — scores are not directly comparable.

Lenses

  • Code Health 100 → 100 (+0.0)
  • Architecture 69 → 69 (+0.0)
  • Maturity 62 → 62 (+0.0)
  • Readiness 25 → 29 (+3.5)
  • Security 94 → 95 (+0.9)
  • Domain Modelling 100 → 100 (+0.0)

Resolved (13)

  • Dependency hygiene not measured — dependency manifest found but not parsed for hygiene
  • High vulnerability: [GHSA redacted] (Cargo.lock)
  • Medium CVE: [GHSA redacted] (Cargo.lock)
  • Medium IaC: CKV_DOCKER_2 (Dockerfile)
  • Medium IaC: CKV_DOCKER_9 (Dockerfile)
  • Medium advisory (unsound): RUSTSEC-2026-0097 (Cargo.lock)
  • Medium advisory (unsound): RUSTSEC-2026-0134 (Cargo.lock)
  • Medium advisory (unsound): RUSTSEC-2026-0135 (Cargo.lock)
  • No exposed public API
  • early-stage repository — too little history to judge knowledge freshness
  • git history depth insufficient
  • git history depth insufficient
  • single-maintainer — knowledge-concentration (bus factor) risk

New (23)

  • Documentation: no contributor guidance (README.md)
  • Documentation: no installation or build instructions (README.md)
  • Documentation: no usage examples (README.md)
  • High IaC: DS-0017 (Dockerfile)
  • High vulnerability: [GHSA redacted] (Cargo.lock)
  • Medium CVE: [GHSA redacted] (Cargo.lock)
  • Medium IaC: WD-COMPOSE-0002 (compose.yaml)
  • Medium IaC: WD-DOCKER-0003 (Dockerfile)
  • Medium IaC: WD-DOCKER-0003 (Dockerfile)
  • Medium advisory (unsound): RUSTSEC-2026-0097 (Cargo.lock)
  • Medium advisory (unsound): RUSTSEC-2026-0134 (Cargo.lock)
  • Medium advisory (unsound): RUSTSEC-2026-0135 (Cargo.lock)
  • No ADRs found
  • Outdated: axum
  • Outdated: axum-macros
  • Outdated: chrono
  • Outdated: diesel
  • Outdated: diesel_migrations
  • Outdated: serde
  • Outdated: serde_json
  • …and 3 more

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

Survey your own repository

Quentin-Piot/axum-diesel-real-world was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.

About this page

  • The score is its most recent published measurement, taken on 21 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
  • Measured at commit 29a1ae0dc839d00a128a8a90ed8b91f4301da061 — the exact code this score is about.
  • Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
  • Measured by watchdog.canine.dev using codehealth-analyzer preprod-fa71c66cabd8.