PHPackages                             borschphp/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. borschphp/cache

ActiveLibrary[Caching](/categories/caching)

borschphp/cache
===============

A simple PSR-6 and PSR-16 implementation.

2.0.0(1y ago)087MITPHPPHP ^8.2CI passing

Since May 12Pushed 1y agoCompare

[ Source](https://github.com/borschphp/borsch-cache)[ Packagist](https://packagist.org/packages/borschphp/cache)[ RSS](/packages/borschphp-cache/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (2)Dependencies (6)Versions (4)Used By (0)

Borsch Cache
============

[](#borsch-cache)

A simple PSR-6 and PSR-16 implementation.

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

[](#installation)

Via [composer](https://getcomposer.org/) :

```
composer require borschphp/cache
```

Usage
-----

[](#usage)

```
// PSR-16 style
$cache = new Cache(new ArrayCacheItemPool());
$cache->set('foo', 'bar');

$foo = $cache->get('foo', 'default_value');

$cache->delete('foo');
$cache->clear();

// PSR-6 style
$pool = new ArrayCacheItemPool();
$pool->save(new CacheItem('foo', 'bar'));

if ($pool->hasItem('foo')) {
    $foo = $pool->getItem('foo')->get();

    $pool->deleteItem('foo');
}

$pool->clear();
```

A `LoggerInterface` instance can be given as a second parameter to the `Cache` class to log errors during cache operations.

License
-------

[](#license)

The package is licensed under the MIT license.
See [License File](https://github.com/borschphp/borsch-cache/blob/master/LICENSE.md) for more information.

###  Health Score

32

—

LowBetter than 72% of packages

Maintenance49

Moderate activity, may be stable

Popularity9

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity55

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

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 ~179 days

Total

3

Last Release

374d ago

Major Versions

1.0.0 → v2.x-dev2025-05-06

PHP version history (2 changes)1.0.0PHP ^8.1

v2.x-devPHP ^8.2

### Community

Maintainers

![](https://www.gravatar.com/avatar/0e1a70117520fe10a630d61c750bbe6888d174e9903825e741470f818ee2c5d1?d=identicon)[debuss-a](/maintainers/debuss-a)

---

Top Contributors

[![debuss](https://avatars.githubusercontent.com/u/2537607?v=4)](https://github.com/debuss "debuss (5 commits)")

---

Tags

psrcachepsr-16psr-6

###  Code Quality

TestsPest

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

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

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

###  Alternatives

[laminas/laminas-cache

Caching implementation with a variety of storage options, as well as codified caching strategies for callbacks, classes, and output

1076.9M130](/packages/laminas-laminas-cache)[cache/simple-cache-bridge

A PSR-6 bridge to PSR-16. This will make any PSR-6 cache compatible with SimpleCache.

423.1M27](/packages/cache-simple-cache-bridge)[codeigniter4/cache

PSR-6 and PSR-16 Cache Adapters for CodeIgniter 4

1320.1k](/packages/codeigniter4-cache)

PHPackages © 2026

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