rekalogika/psr-16-simple-cache-bundle
A Symfony bundle for integrating PSR-16 simple cache implementations into your app, with service configuration and autowiring so you can use interoperable, lightweight caching through the framework’s dependency injection.
What this package is. Despite the "Laravel/PHP package" framing in the request, rekalogika/psr-16-simple-cache-bundle is a Symfony bundle that provides a PSR-16 (Simple Cache) implementation wired into the Symfony DI container. Release 1.2.0 is a maintenance release: PHP 8.4 compatibility, PHPUnit/coding-standard updates, and Dependabot-driven CI bumps (actions/checkout 3→4, actions/cache 3→4, ramsey/composer-install 2→3, psalm/plugin-phpunit 0.18→0.19). There are no new features, no deprecations, and no documented breaking changes in the changelog.
Architecture fit. The value proposition is narrow and clean: a PSR-16 CacheInterface adapter backed by Symfony's cache contracts, letting application code depend on the PSR-16 interface rather than a framework-specific one. That is a good architectural boundary for libraries shared across frameworks, but it is not a Laravel-native package. Laravel already ships Illuminate\Contracts\Cache\Repository and has PSR-16 bridges (Illuminate\Cache\Repository + Psr16Cache adapter via symfony/cache). Adopting this bundle in a Laravel codebase would mean pulling Symfony bundle machinery (Bundle class, services.yaml, compiler passes, Flex recipes) into an app that does not boot a Symfony kernel — the bundle would effectively be inert, and only the underlying library (not the bundle) would be usable.
Integration feasibility.
composer require rekalogika/psr-16-simple-cache-bundle, enable in config/bundles.php, autowire Psr\SimpleCache\CacheInterface. PHP 8.4 support in 1.2.0 is the meaningful upgrade driver.Psr\SimpleCache\CacheInterface to new Psr16Cache(app('cache')->store()) in a service provider — using symfony/cache's adapter directly and skipping this bundle entirely — or (b) accept a mixed Symfony/Laravel dependency tree. Option (a) is the pragmatic path, and it means this package adds little to no value for a Laravel stack.Technical risk. Low severity overall, but worth flagging:
@priyadi) plus Dependabot. Bus factor is 1. That is the dominant long-term risk for a dependency sitting in the caching hot path.{}()/\@: reserved characters), and the null vs. miss ambiguity are classic cache-integration bug sources; the bundle does not change these, but inheriting them silently is a risk if the team has not used PSR-16 before.Key questions for the maintainer / vendor review.
DateInterval) and key-escaping?Stack fit. Treat this as a Symfony-only dependency. For a Laravel codebase, the correct integration is not this bundle but a thin PSR-16 binding in a service provider:
$this->app->singleton(\Psr\SimpleCache\CacheInterface::class, fn ($app) =>
new \Symfony\Component\Cache\Psr16Cache(
$app['cache']->store(config('cache.default'))
)
);
That achieves the same architectural goal — code depending on PSR-16 rather than Laravel's cache contract — with one fewer framework and no bundle bootstrap. Any decision record should state this explicitly so future maintainers do not re-litigate it.
Migration path. Upgrade is trivial for existing Symfony consumers: bump ^1.1 to ^1.2, run composer update rekalogika/psr-16-simple-cache-bundle, clear the container cache, run the test suite. No code changes are implied by the release notes. The only functional delta is PHP 8.4 support, so the migration is gated on whether the runtime is on 8.4 — PHP 8.2/8.3 users gain nothing but risk nothing.
Compatibility. Verify composer why-not against the pinned Symfony minor, psr/simple-cache version, and symfony/cache version before merging. The PHPUnit and Psalm plugin bumps are dev-only and cannot leak into production autoload; confirm by checking that the diff touches only require-dev and CI workflow files.
Sequencing.
Maintenance. Very low ongoing cost for the code, moderate cost for the dependency review. The package changes rarely, and 1.2.0 is overwhelmingly housekeeping. The realistic maintenance burden is the quarterly "is this still alive?" check plus Dependabot noise. Because the maintainer count is effectively one, assign an explicit owner and a documented exit plan: the fallback is a handful of lines wiring symfony/cache's Psr16Cache directly, which is a same-day migration. That low switching cost is the strongest argument in favor of adopting it at all.
Support. Community-only, best-effort, GitHub issues. No SLA, no commercial backing, no LTS branch. Acceptable for internal applications; a harder sell for anything with an uptime contract. For regulated environments, note that no security policy or coordinated disclosure process is documented in the release notes.
Scaling. Caching layers scale with the backing store, not with this bundle — the bundle is DI wiring and adds no meaningful overhead. The PSR-16 abstraction itself serializes through the underlying Symfony cache adapter, which is where hit-ratio, stampede protection, and namespace-collision behavior actually live. Size and stress-test the backend store (Redis/Memcached/APCu), not this package. The one scaling caveat worth writing down: PSR-16's simple get/set surface has no tags, no atomic increment, and no lock primitive — if the product roadmap needs cache tags or counters, plan for a second, richer client alongside it.
Failure modes.
{}()/\@: are reserved) or from storing null; both degrade performance without surfacing an error. Add an assertion test for the reserved-character set rather than relying on the library to throw.Ramp-up. Minutes for a Symfony developer — it is a standard bundle plus a PSR-16 interface they likely already know. The real ramp-up cost is conceptual, not mechanical: engineers must internalize PSR-16's limitations (no tags, no atomicity, key restrictions, TTL semantics) so they do not reach for capabilities the abstraction does not offer. Budget a short internal write-up or brown-bag on the PSR-16 contract, and note in the ADR that this package is Symfony-scoped. For a Laravel team, ramp-up on this bundle should be zero because the recommendation is not to adopt it.
How can I help you explore Laravel packages today?