padam87 / doctrine-cache-invalidator-bundle
一种简单的无效化Doctrine结果缓存的方法。
v1.0.3
2017-04-18 12:17 UTC
Requires
- php: >=5.4.0
- doctrine/orm: ^2.2.3
- symfony/framework-bundle: ~2.4|~3.0
- symfony/property-access: ~2.3|~3.0
Requires (Dev)
- mockery/mockery: ~0.9
- phpunit/phpunit: ~4.4
This package is auto-updated.
Last update: 2024-09-23 04:22:16 UTC
README
一种简单的无效化Doctrine结果缓存的方法
请在使用此包之前查看官方Doctrine无效化说明: http://doctrine-orm.readthedocs.org/en/latest/reference/second-level-cache.html
如果你需要一个完整的二级缓存,这不是你要找的包。但是,如果你想要缓存一些 自定义查询结果,这可能会对你有所帮助。
使用方法
目前仅支持 注解 配置。
use Padam87\DoctrineCacheInvalidatorBundle\Annotation\InvalidateCache; /** * @ORM\Entity() * @InvalidateCache("my_cache_key", events = {"PERSIST", "DELETE"}) */ class Entity { // ... }