Download the PHP package silviooosilva/cacheer-php without Composer
On this page you can find all versions of the php package silviooosilva/cacheer-php. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download silviooosilva/cacheer-php
More information about silviooosilva/cacheer-php
Files in silviooosilva/cacheer-php
Package cacheer-php
Short Description CacheerPHP is a minimalist package for caching in PHP, offering a simple interface for storing and retrieving cached data using multiple backends.
License MIT
Homepage https://github.com/silviooosilva
Informations about the package cacheer-php
CacheerPHP
CacheerPHP is a minimalist package for PHP caching. Now, in version 4.0.0, you get even more flexibility, support for multiple backends (files, database and Redis), as well as new features for monitoring, compression and encryption and a more robust API design.
Features
- Cache Storage and Retrieval: Support for file storage, databases (MySQL, PostgreSQL, SQLite) and Redis.
- Customizable expiration: Set the TTL (Time To Live) of the cache precisely.
- Cache cleaning and flushing: Support for manual and automatic cleaning (via
flushAfter
). - Namespace support: Organize your cache entries by category.
- Customized Data Output: Options to return data in
JSON
,Array
,String
orObject
. - Compression and Encryption: Reduce storage space and increase the security of cached data.
- Cache Statistics and Monitoring: Track hit and miss statistics and average read/write times (Coming Soon).
- Advanced Logging: Detailed monitoring of the operation of the caching system.
Installation
CacheerPHP 4.0.0 is available via Composer. Add the following line to your composer.json file:
Or run the command:
IMPORTANT WARNING!!!
Don't forget to set your environment variables in the .env.example file.
Remember that they must be set in the .env file, not in .env.example. To do this, do the following on your command line:
Documentation
- Storing and retrieving cached data
- Customizable cache expiration
- Cache flushing and cleaning
- Namespace support for cache organization
- Automatic cleaning of the
flushAfter
cache directory - API Response Cache
- Custom Data Output (
JSON
) - Custom Data Output (
Array
) - Custom Data Output (
String
) - Upgrade Guide for Version 2.0.0
- API Reference
- API Reference - Cache Functions
Several practical examples are also available in the Examples folder in the root of the project.
Compatibility
- PHP: 8.0 or higher.
- Database Drivers: MySQL, PostgreSQL, SQLite.
- Redis
Tests
To run the tests, go to the root of the project and type the command: