Download the PHP package telcolab/cacher without Composer
On this page you can find all versions of the php package telcolab/cacher. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download telcolab/cacher
More information about telcolab/cacher
Files in telcolab/cacher
Package cacher
Short Description A Laravel's package that automatically cache and invalidate Eloquent queries.
License MIT
Homepage https://github.com/telcolab/cacher
Informations about the package cacher
Cacher - Caching Eloquent Query
Cacher is a package that automatically cache Eloquent query. With Cacher it's super easy to cache all eloquent query including relationships.
This package works by checking if the query hasn't been executed & cached before and if it doesn't, it will execute the SQL query generated by Eloquent and cache the results. If the query has been cached previously it'll just retrieve it from cache store instead of database.
Requirements
- PHP >= 7
- Laravel >= 5.1
- Taggable Cacher Driver - Redis/Memcached
Installation
Install using Composer, just as you would anything else.
After the installation is completed just open up your Model and use trait. Let's say you have a model name .
Usage
After that you just call use Eloquent normally you use and Cacher will automatically cache subsequent query. For example in your controller,
Cache lifetime
By default Cacher will cache all the result 24 hours, you may alter this by changing the property (in minutes).
Cache lifetime per query.
You also may change how long specific query will be cached.
Cache flushing
You may flush the cache manully by calling the flush method on the model or let Cacher flush automatically when you insert/update/delete the model.
Contributing
Thank you for considering contributing to the Cacher package! You may contribute by fork and make a pull request to this repository.
Security Vulnerabilities
If you discover a security vulnerability within Cacher, please send an e-mail to Haries at [email protected] . All security vulnerabilities will be promptly addressed.
License
The Laravel Standalone Package Creator is open-sourced software licensed under the MIT license.
Jobs
Our office is located in Seri Kembangan, Selangor. Our working time is flexible. Incase you're interested to join our team, you may shoot us an email at [email protected]. Knowing Laravel and its best practices is a plus.
All versions of cacher with dependencies
illuminate/database Version 5.1.*|5.2.*|5.3.*|5.4.*|5.5.*
illuminate/cache Version 5.1.*|5.2.*|5.3.*|5.4.*|5.5.*