PHPackages                             wyrihaximus/react-cache-psr-16-adapter - 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. wyrihaximus/react-cache-psr-16-adapter

ActiveLibrary[Caching](/categories/caching)

wyrihaximus/react-cache-psr-16-adapter
======================================

🔌 PSR-16 adapter

1.1.0(2y ago)23841[8 PRs](https://github.com/WyriHaximus/reactphp-cache-psr-16-adapter/pulls)MITPHPPHP ^8.2

Since Aug 12Pushed 1mo ago1 watchersCompare

[ Source](https://github.com/WyriHaximus/reactphp-cache-psr-16-adapter)[ Packagist](https://packagist.org/packages/wyrihaximus/react-cache-psr-16-adapter)[ GitHub Sponsors](https://github.com/WyriHaximus)[ RSS](/packages/wyrihaximus-react-cache-psr-16-adapter/feed)WikiDiscussions main Synced 1mo ago

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

[ReactPHP](https://reactphp.org/) [PSR-16](https://www.php-fig.org/psr/psr-16/) cache adapter
=============================================================================================

[](#reactphp-psr-16-cache-adapter)

[![Continuous Integration](https://github.com/WyriHaximus/reactphp-cache-psr-16-adapter/actions/workflows/ci.yml/badge.svg)](https://github.com/WyriHaximus/reactphp-cache-psr-16-adapter/actions/workflows/ci.yml)[![Latest Stable Version](https://camo.githubusercontent.com/0fe21ce84d9a3f610c6cf3c78316275fd6ae5fc97378f4d943db86cf5f28ddb8/68747470733a2f2f706f7365722e707567782e6f72672f57797269486178696d75732f72656163742d63616368652d7073722d31362d616461707465722f762f737461626c652e706e67)](https://packagist.org/packages/WyriHaximus/react-cache-psr-16-adapter)[![Total Downloads](https://camo.githubusercontent.com/10102cff6e8d2cc3366f34b11269c41dbc76db533f24e1bbef33fb687445ecb0/68747470733a2f2f706f7365722e707567782e6f72672f57797269486178696d75732f72656163742d63616368652d7073722d31362d616461707465722f646f776e6c6f6164732e706e67)](https://packagist.org/packages/WyriHaximus/react-cache-psr-16-adapter/stats)[![License](https://camo.githubusercontent.com/f990f099bc69e212e3b730d46a9fe7ddaf8c162e592d9e64ed4879ba933ac731/68747470733a2f2f706f7365722e707567782e6f72672f57797269486178696d75732f72656163742d63616368652d7073722d31362d616461707465722f6c6963656e73652e706e67)](https://packagist.org/packages/wyrihaximus/react-cache-psr-16-adapter)

### Installation

[](#installation)

To install via [Composer](http://getcomposer.org/), use the command below, it will automatically detect the latest version and bind it with `^`.

```
composer require wyrihaximus/react-cache-psr-16-adapter

```

Usage
-----

[](#usage)

Take any [`react/cache`](https://reactphp.org/cache/) implementation, like [`wyrihaximus/react-cache-redis `](https://github.com/WyriHaximus/reactphp-cache-redis) we'll be using in this example. Decorate it with a `PSR16Adapter` instance, and you can use them as a PSR-16 cache within fibers. Directly, or with other packages. Internally `PSR16Adapter` uses [`await`](https://reactphp.org/async/#await) on every method call to the `react/cache` implementation to make it compatible.

```
$cache = new PSR16Adapter(new Redis($reditClient, 'react:cache:your:key:prefix:'));

React\Async\async(function () {
    $cache->set('key', 'value'); // All methods use `await` internally to make any ReactPHP cache PSR-16 compatible
    echo $cache->get('key'); // echos: value
})();
```

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

License
-------

[](#license)

Copyright 2022 [Cees-Jan Kiewiet](https://wyrihaximus.net/)

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

###  Health Score

42

—

FairBetter than 90% of packages

Maintenance61

Regular maintenance activity

Popularity16

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity67

Established project with proven stability

 Bus Factor1

Top contributor holds 64.4% 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 ~598 days

Total

2

Last Release

770d ago

PHP version history (2 changes)1.0.0PHP ^8.1

1.1.0PHP ^8.2

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/147145?v=4)[Cees-Jan Kiewiet](/maintainers/WyriHaximus)[@WyriHaximus](https://github.com/WyriHaximus)

---

Top Contributors

[![WyriHaximus](https://avatars.githubusercontent.com/u/147145?v=4)](https://github.com/WyriHaximus "WyriHaximus (38 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (14 commits)")[![renovate[bot]](https://avatars.githubusercontent.com/in/2740?v=4)](https://github.com/renovate[bot] "renovate[bot] (7 commits)")

### Embed Badge

![Health badge](/badges/wyrihaximus-react-cache-psr-16-adapter/health.svg)

```
[![Health](https://phpackages.com/badges/wyrihaximus-react-cache-psr-16-adapter/health.svg)](https://phpackages.com/packages/wyrihaximus-react-cache-psr-16-adapter)
```

###  Alternatives

[team-reflex/discord-php

An unofficial API to interact with the voice and text service Discord.

1.1k379.4k24](/packages/team-reflex-discord-php)[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/adapter-common

Common classes for PSR-6 adapters

11124.4M38](/packages/cache-adapter-common)[cache/filesystem-adapter

A PSR-6 cache implementation using filesystem. This implementation supports tags

705.8M82](/packages/cache-filesystem-adapter)[cache/array-adapter

A PSR-6 cache implementation using a php array. This implementation supports tags

548.3M151](/packages/cache-array-adapter)[cache/redis-adapter

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

523.9M27](/packages/cache-redis-adapter)

PHPackages © 2026

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