Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message
Cache Bundle

Cache Bundle Laravel Package

tbbc/cache-bundle

TbbcCacheBundle integrates a configurable caching layer into Symfony applications, exposing cache services and helpers for storing, retrieving, and invalidating data across common cache backends. It simplifies cache setup and reuse in Symfony projects.

View on GitHub
Deep Wiki
Context7

Cache abstraction bundle for Symfony 2

Frequently asked questions about Cache Bundle
Is TbbcCacheBundle compatible with Laravel?
No. TbbcCacheBundle is a Symfony bundle, not a Laravel package, and it depends on Symfony's bundle registration, DI container compilation, event dispatching, and Doctrine annotation reading. None of those primitives map onto Laravel's service container, facades, or middleware pipeline. Using it in Laravel would require writing an adapter layer rather than simply integrating the package. For a Laravel app, treat this as a reject and look at native Cache or a Laravel-specific alternative.
Which Symfony versions does TbbcCacheBundle actually support?
That is not clearly documented and must be verified by reading the package's composer.json constraints before you make any decision. The package originated in the Symfony 2 era, so support for Symfony 5, 6, or 7 is uncertain and likely absent. Spin up a sandbox install to confirm the minimum and maximum supported Symfony and PHP versions. Do not assume modern Symfony compatibility from the overview alone.
Can I install tbbc/cache-bundle in a Laravel project with Composer?
Composer may resolve it in isolation, but installing it into a Laravel app is a bad idea. It drags a Symfony dependency tree into your composer.json, including symfony components and likely doctrine/annotations or sensio/framework-extra-bundle, which will conflict with the Symfony components Laravel already pins. The result is dependency resolution pain and a heavier, riskier lockfile. The integration feasibility for Laravel is low by design.
Does TbbcCacheBundle require doctrine/annotations?
The bundle's caching model is driven by method-level @Cache docblock annotations read through an annotation reader, which strongly implies a dependency on doctrine/annotations. That library is deprecated in favor of PHP 8 attributes, and the surrounding reader ecosystem has been progressively abandoned. Runtime annotation parsing is also fragile under opcache and preloading. Check composer.json to confirm the exact requirement before relying on it.
How does TbbcCacheBundle compare to Laravel's Cache facade and Cache::remember()?
Laravel already provides a first-class cache abstraction through the Cache facade, with drivers for Redis, Memcached, database, file, and more. Cache::remember() gives you the read-through, store-on-miss pattern in a single expressive call, and invalidation is explicit via forget and flush. TbbcCacheBundle offers no meaningful advantage for a Laravel codebase and adds a second, incompatible abstraction. The only thing it adds is docblock-declared cache behavior, which you can replicate with a small internal decorator.
Is TbbcCacheBundle still actively maintained?
Every available signal points to dormant or single-maintainer status: roughly 36 stars, zero dependents, and a low overall assessment score. With no downstream pressure, fixes and security patches for transitive dependencies are unlikely to land upstream. Budget for a fork-and-own model or an internal replacement if you decide to adopt the concept. There is no vendor, SLA, or meaningful community support around it.
Does TbbcCacheBundle work on PHP 8.2 and newer?
This has not been confirmed and is unlikely without verification. The package targets the Symfony 2 era and relies on annotation reading, a pattern that has been largely superseded by PHP 8 attributes. Annotation parsing at runtime is also vulnerable to opcache and preloading behavior on modern PHP runtimes. Test in a throwaway sandbox on PHP 8.2 or 8.3 before considering it for anything real.
How do I get method-level caching in Laravel without this bundle?
Build a small internal attribute-based decorator on top of Laravel's Cache facade, on the order of 100 to 150 lines. Declare something like #[Cacheable(ttl: 300)] on service methods and resolve it via reflection inside a service provider, then wrap the call in Cache::remember(). That gives you the same declared-cache ergonomics without pulling in a Symfony dependency tree. Keep it behind an internal interface so you can swap the implementation later, and never couple business code directly to a third-party annotation.
What are the production risks of runtime annotation parsing like this?
Symfony mitigates runtime annotation parsing with a cache warmup and compile step, and you would have to replicate that discipline or pay per-request reflection costs. Opcache and preloading can interact badly with annotation readers, producing hard-to-reproduce failures. The bigger operational risk is cache invalidation semantics: annotation-declared TTLs with no explicit invalidation hooks can serve stale data under fan-out and write-heavy loads. Plan explicit invalidation points rather than relying on TTL expiry alone.
Can I fork TbbcCacheBundle and port it to Laravel?
The MIT license is permissive, so forking is legally viable, but the technical work is non-trivial. You would be replacing Symfony bundle registration, container compilation, and the annotation reader with Laravel service providers, facades, and PHP attributes. It is almost always cheaper to extract the concept and write a fresh, small implementation than to port the code. If you do port it, isolate it behind an internal interface and inspect the upstream composer.json and last-commit date first.
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
dbravoan/dbcms-admin-theme-dbcms
dbravoan/dbcms-theme-db-cyber
dbravoan/dbcms-blocks-basic
dbravoan/dbcms-module-content-audit
dbravoan/dbcms-module-ai-assistant
paygate-to/paygate-php
padosoft/askmydocs-connector-base
defstudio/supercharged-carbon
bernskioldmedia/laravel-matomo
bernskioldmedia/laravel-harvest
bernskiold/laravel-data-scrubber
bernskiold/laravel-currency-converter
bernskiold/laravel-campaign-monitor
bernskioldmedia/laravel-autotranslate
siberfx/telegram-bot
roy-sandip/laravel-view-extended
gregsphotography/site-builder-core
roy-sandip/laravel-view
anodyne/blade-fluentui-icons
webx-ui/module-catalog-collections