Repository navigation
v1.0.0
First stable release of Solo Repository (solophp/repository): typed PHP repositories on Doctrine DBAL. Map a table to your own objects, read through reusable queries, write explicitly, and get translations with one fallback rule and relations loaded in batches.
The code is that of v1.0.0-RC6; two applications run it in production.
What 1.0 covers
- Explicit, typed
MappingandRepository, which an application can extend into a typed repository per table. - Reusable
ReadQuerywith projections, aggregates, bounded iteration by ID,queryBuilder()and ordering by fields ofBelongsTotargets. Filter::all,any,notand relatedEXISTSpredicates, with values checked against their field type before SQL.- Translations with one fallback rule for reading, filtering and sorting, and PATCH upserts through
TranslationStore. - Four relation types with nested batch loading, locale inheritance and per-relation visibility.
- Soft delete, native upserts, atomic
insertMany,LinkSetpivot writes,lockForUpdate()and locking reads withforUpdate(). - Tested on MySQL 8.4, MariaDB 12.3, PostgreSQL 17 and SQLite, with PHP 8.3–8.5 and DBAL 4.3+.
From now on the public API follows semantic versioning; see the API reference for what it covers and the rules for typed repositories.
Install
composer require solophp/repositorySee the documentation, the changelog and the full diff since RC6.