PHPackages                             philippwitzmann/cache - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Caching](/categories/caching)
4. /
5. philippwitzmann/cache

ActiveLibrary[Caching](/categories/caching)

philippwitzmann/cache
=====================

Cache Framework

1.3.3(6y ago)0307proprietaryPHPPHP &gt;=7.2CI failing

Since Dec 31Pushed 6y ago1 watchersCompare

[ Source](https://github.com/PhilippWitzmann/Cache)[ Packagist](https://packagist.org/packages/philippwitzmann/cache)[ RSS](/packages/philippwitzmann-cache/feed)WikiDiscussions master Synced 1w ago

READMEChangelogDependencies (5)Versions (3)Used By (0)

Cache
=====

[](#cache)

This library aims to provide basic functionality to work with (testable, interchangable) Cache implementations

Installation
------------

[](#installation)

```
composer require philippwitzmann/cache
```

Usage
-----

[](#usage)

### Create an instance

[](#create-an-instance)

```
$dateTimeHandler = new DateTimeHandler();
$arrayCache      = new ArrayCache($dateTimeHandler);
```

### Set Values

[](#set-values)

```
$client = new Client([
    'scheme' => 'tcp',
    'host'   => '127.0.0.1',
    'port'   => 6379,
]);
$dateTimeHandler = new DateTimeHandler();
$arrayCache      = new ArrayCache($dateTimeHandler);
$redisCache      = new RedisCache($dateTimeHandler, $client);
$arrayCache->set('key', 'value', 600); // 600 is Lifetime In Seconds so 10Minutes.
$redisCache->set('key', 'value', 600); // 600 is Lifetime In Seconds so 10Minutes.

echo $arrayCache->get('key'); // Outputs: 'value'
```

Running tests
-------------

[](#running-tests)

```
php vendor/bin/phpunit --configuration config/phpunit.xml
```

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity12

Limited adoption so far

Community4

Small or concentrated contributor base

Maturity53

Maturing project, gaining track record

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~34 days

Total

2

Last Release

2296d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/36b7e5183f1f5da9648653b84421f6fc9e05845222ceea8b3b541ec7e2b01faa?d=identicon)[PhilippWitzmann](/maintainers/PhilippWitzmann)

### Embed Badge

![Health badge](/badges/philippwitzmann-cache/health.svg)

```
[![Health](https://phpackages.com/badges/philippwitzmann-cache/health.svg)](https://phpackages.com/packages/philippwitzmann-cache)
```

###  Alternatives

[rhubarbgroup/redis-cache

A persistent object cache backend for WordPress powered by Redis. Supports Predis, PhpRedis, Relay, replication, sentinels, clustering and WP-CLI.

51795.3k1](/packages/rhubarbgroup-redis-cache)[monospice/laravel-redis-sentinel-drivers

Redis Sentinel integration for Laravel and Lumen.

103830.5k](/packages/monospice-laravel-redis-sentinel-drivers)[jamescauwelier/psredis

Sentinel client for the popular php redis client

77392.9k5](/packages/jamescauwelier-psredis)[cache/predis-adapter

A PSR-6 cache implementation using Redis (Predis). This implementation supports tags

272.6M13](/packages/cache-predis-adapter)[symfony-bundles/redis-bundle

Symfony Redis Bundle

271.1M5](/packages/symfony-bundles-redis-bundle)[pdffiller/qless-php

PHP Bindings for qless

29113.2k1](/packages/pdffiller-qless-php)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
