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
Phpfastcache Bundle

Phpfastcache Bundle Laravel Package

phpfastcache/phpfastcache-bundle

Symfony bundle that integrates PhpFastCache into your application, letting you configure and inject cache services backed by files, Redis, Memcached, APCu, and other drivers through standard Symfony configuration. A lightweight way to add flexible, multi-backend caching.

View on GitHub
Deep Wiki
Context7

The symfony 3/Flex bundle for PhpFastCache integrating a phpfastcache service, a twig cache tag and a powerfull cache profiler integrated to the symfony profile

Frequently asked questions about Phpfastcache Bundle
Is phpfastcache/phpfastcache-bundle compatible with Laravel?
No. phpfastcache/phpfastcache-bundle is a Symfony bundle and does not ship a Laravel service provider, facade, or package auto-discovery entry. In Laravel you would use Laravel's own cache layer or wire phpFastCache manually rather than installing this bundle.
Which Symfony versions does phpfastcache-bundle support?
Version 3.0.0 targets Symfony 3.4 and Symfony 4.4 (Flex), with a Composer constraint in the ^3.4|^4.0 style. It does not support Symfony 5.4, 6, or 7, because container and Flex conventions changed after 4.4. Always read the actual composer.json constraint before starting a spike.
How do I install phpfastcache/phpfastcache-bundle in Symfony?
Install it with Composer and enable the bundle in your Symfony kernel or bundles.php for Flex applications. Then define your cache instances in Symfony configuration, choosing a backend such as files, APCu, Redis, or Memcached. The bundle turns each configured instance into a service so you can inject it instead of building caches by hand.
What cache backends can I use with phpfastcache-bundle?
The bundle supports phpFastCache drivers including files, APCu, Redis, and Memcached, and other phpFastCache backends should be usable through configuration. Capability and performance come from phpFastCache itself, not from the bundle, so review the driver notes for your version. The bundle is mainly DI wiring on top of those drivers.
How do I inject a phpFastCache cache service into a Symfony controller or service?
Configure the cache instance in Symfony config and let the bundle expose it as a service, then type-hint or alias that service in your constructor or controller action. In 3.0.0 the phpfastcache service is private and namespaces changed, so code that fetched it by ID will fail. Follow the migration guide and inject the configured service instead.
Why is my phpfastcache service private after upgrading to 3.0?
That is an intentional breaking change in 3.0.0: the phpfastcache service became private and several namespaces changed. Code that calls the container directly with get('phpfastcache') or imports old FQCNs will break at container compile or autoload time. Read the migration guide and update injection paths and imports before upgrading.
Does phpfastcache-bundle support PSR-6 and PSR-16?
Yes, through phpFastCache's PSR-6 and PSR-16-compatible APIs, which the bundle exposes behind its Symfony services. You can use the cache pool interfaces for standard get, set, and delete operations rather than driver-specific calls. That keeps application code portable if you later switch to symfony/cache.
What is Cacheable Response in phpfastcache-bundle 3.0?
Cacheable Response is a new 3.0.0 feature that moves caching to the HTTP response layer, covering concerns like ETag, Last-Modified, Vary, freshness, and invalidation. It overlaps with Symfony's own HttpCache, so treat it as correctness-sensitive code, not a drop-in speed toggle. Review how it handles Vary, private, and no-store before caching user-specific content.
Are the phpfastcache CRUD console commands safe in production?
The 3.0.0 release adds console commands for create, read, update, and delete-style cache operations, and they are operationally convenient but destructive. Check whether they register by default and whether your version prompts for confirmation or supports environment checks and --force. Environment-gate or disable them in production.
Is phpfastcache/phpfastcache-bundle actively maintained?
It has a single maintainer with renewed activity around 3.0.0, but the star count and dependent count remain small, and the repository's archive status is not confirmed by the release notes. There is no published roadmap for Symfony 5.4, 6, or 7. Treat it as forkable and vendorable, and verify CI coverage and security fixes for phpFastCache v7 before adoption.
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.
middlewares/firewall
qubiqx/montapacking
nyoncode/laravel-package-console
pnscripts/filament-broadquill-lite
pnscripts/laravel-sentfold-lite
vleap/mx-sdk-laravel-internal
twidpay/utils
htetmyathlaing/scout-elasticsearch-driver
artisan-toolbox/front-awesome
ls/client-assistant
users-au/laravel-client
cgv/localized-resource
noith/settings
kda/laravel-package
kda/filament-dynamic-navigation
bypersoft/signbox
pairus/product-data
fayne/laravel-filament-cms-core
nodisrupt/laravel-agent
sierratecnologia/media-manager