# ADR-0008 — Platform upgrades: PHP 7.4 and MariaDB compatibility

> Produced by the Reversa **Detective** (phase: interpretation) · doc_level: `complete`
> Retroactive ADR reconstructed from Git history: MR!19 "System | Upgrade php version to 7.4.33" (`a7b45f0`), MR!21 "SQL | Fixed error by mariadb version" (`f9320cd`), and `docs(reversa): ... correct DB engine to MariaDB` (`0372b38`).

- **Status:** Accepted (as-built) 🟢
- **Confidence:** 🟢 CONFIRMED

## Context

The app began on an older PHP/Laravel 5.5–5.6 stack. Hosting and security realities required moving to PHP 7.4.33, and the database in use is **MariaDB** (not vanilla MySQL), which differs in strictness/behaviour for some SQL used by the raw statistics queries.

## Decision

- Pin the runtime to **PHP 7.4.33** (MR!19).
- Adjust SQL to MariaDB's behaviour where the raw aggregation queries broke (MR!21). The reversa docs were corrected to record the engine as MariaDB.

## Consequences

- 🟢 Establishes the supported runtime for any forward/migration work: PHP 7.4, Laravel 5.5/5.6, MariaDB.
- 🟡 The Encore\Admin fork (ADR-0001) caps how far the framework can be upgraded without replacing the admin layer.
- 🟡 Raw-SQL statistics (ADR-0005/0006) are the parts most sensitive to DB-engine version changes — the MariaDB fix confirms this fragility.
