matthewbdaly/laravel-repositories
Architecture fit
The package is deliberately minimal: an abstract base repository, a matching interface, and a caching decorator that wraps repository calls in Cache::remember-style logic. It is not an opinionated architecture — it is boilerplate reduction for teams that have already decided to adopt the repository pattern over Eloquent. That distinction matters for a TPM: the package does not de-risk the architectural decision, it only removes ~150 lines of typing after the decision is made. It has no service provider, no auto-binding, and no conventions for pagination, filtering, eager loading, or transaction boundaries, so every consuming team will diverge in how they extend it.
Integration feasibility Technically trivial and organisationally questionable. The entire value proposition is two or three classes; a mid-level engineer can reproduce them from the README in under a day. That means the realistic integration options are (a) add a composer dependency on an unmaintained package, or (b) vendor the MIT-licensed source with attribution. Option (b) carries near-zero risk and near-zero cost, which substantially undercuts the case for option (a).
Technical risk — HIGH
| Factor | Assessment |
|---|---|
| Last release | 2018-06-08 — Laravel 5.6 era; predates Laravel 6 LTS through 11.x and PHP 8.x |
| Composer constraints | Almost certainly pins illuminate/* to ^5.x; will fail resolution on modern Laravel without a fork |
| PHP 8 compatibility | Unverified; small surface area but no CI signal to confirm. Expect deprecation noise at minimum |
| Maintainer bus factor | 1, with 12 stars and no activity in ~7 years — treat as abandoned |
| Test coverage | Not evident; you inherit no safety net |
| Security posture | No upstream patches will ever ship; you own any advisory response |
Key questions to answer before committing
composer.json constrain (php, illuminate/support, illuminate/database), and does it resolve against our target Laravel version?Model/Builder types and defeat the abstraction?Stack fit Clean fit for a Laravel 5.x codebase already using the repository pattern. Poor fit for Laravel 9+ / PHP 8.1+, where composer resolution will likely fail out of the box and a fork is mandatory regardless — at which point you are maintaining a fork of an abandoned package, which is strictly worse than maintaining your own code.
Migration path Recommended: treat this as a reference implementation, not a dependency.
app/Repositories/ with attribution retained per MIT.If a dependency is mandated, use a Composer VCS/path repository pointing at an internal fork with widened constraints — never the public Packagist tag.
Compatibility
Confirm three things in order: PHP constraint, illuminate/* constraint, and whether the decorator uses the Illuminate\Contracts\Cache\Repository contract (portable) versus the Cache facade (testability problem). Also check cache key construction for collisions across repositories — a common flaw in decorators of this vintage.
Sequencing
Maintenance Effectively zero upstream maintenance, and that is the core issue: the cost does not disappear, it transfers to your team. Budget a named owner for the vendored code and a defined review cadence tied to Laravel major upgrades. The package will not break loudly — it will break at the worst moment, during a framework upgrade, when the constraint conflict blocks the whole application.
Support No commercial support, no active maintainer, negligible community (12 stars means Stack Overflow answers are effectively nonexistent). Support burden lands entirely on internal engineers reading source. Institutional knowledge concentrates in whoever performed the initial review — a real bus-factor risk for a "small" dependency.
Scaling Two scaling hazards are structural, not incidental:
stale-while-revalidate is added. Neither is likely present in a 2018 package.all() on a base repository invites full-table loads and hides N+1 patterns behind a method call, which reviewers cannot see in the calling code. This is the classic failure mode of thin repository abstractions and it gets worse as data volume grows.Failure modes to plan for
Ramp-up Low for engineers: the surface area is tiny and the pattern is well understood — a day to productivity. That is precisely the problem. The ramp-up cost is near-zero because the package contributes near-zero, which is why the 0.09 score is a fair verdict. The decision to adopt repositories is the expensive, high-judgment call; this package is a footnote to it. Recommendation: consume as a design reference, vendor the source, own the code, and do not add it as a runtime dependency.
How can I help you explore Laravel packages today?