Download the PHP package ordent/cache-url-redis without Composer
On this page you can find all versions of the php package ordent/cache-url-redis. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download ordent/cache-url-redis
More information about ordent/cache-url-redis
Files in ordent/cache-url-redis
Download ordent/cache-url-redis
More information about ordent/cache-url-redis
Files in ordent/cache-url-redis
Vendor ordent
Package cache-url-redis
Short Description AIO Cache Management based on URL and Auth Implementation
License MIT
Package cache-url-redis
Short Description AIO Cache Management based on URL and Auth Implementation
License MIT
Please rate this library. Is it a good library?
Informations about the package cache-url-redis
ORDENT / CACHE-URL-REDIS
AIO cache management service based on URL and Auth JWT Implementation.
How To Use
-
Install the package via composer
-
Implement the providers in your app configurations at
config/app.php
-
Add a constant in the start of your
bootstart/app.php
to measure the execution time of your api. -
Add our middleware in
App\Http\Kernel
to short circuit the computation process to redis when the URL key is found. - Don't forget to set up your
CACHE
env implementation.
Output
- We measure and deliver the endpoint execution time via response header
X-Elapsed-Time
. - You need to send a Header in order to use the caching mechanism. If the header is not found on the request, the request will be computed normally. The header you need to set is
X-Cache-URL
with either value ofwith-auth
orwithout-auth
. - When the value
without-auth
is being used, the application will short circuit the computation process to Redis with finding the key of request URL. - However if the value
with-auth
is used, the application will use the Redis with key format :{application-url}:{authorization-header-value}
withauthorization-header-value
is your JWT token with Bearer format removed. - As of now the cache will last 60 minutes and won't cache another value unless you use header
X-Cache-URL-Invalidate
, you can use it to invalidate the cache value after transaction or any other database change.
All versions of cache-url-redis with dependencies
PHP Build Version
Package Version
Requires
php Version
>=7.2
The package ordent/cache-url-redis contains the following files
Loading the files please wait ....