PHPackages                             suven/flint-redis - 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. suven/flint-redis

ActiveLibrary[Caching](/categories/caching)

suven/flint-redis
=================

wrapper around flintstone and predis

v1.0.0(9y ago)09PHPPHP ~5.6|~7.0

Since Apr 16Pushed 9y ago1 watchersCompare

[ Source](https://github.com/Suven/flintRedis)[ Packagist](https://packagist.org/packages/suven/flint-redis)[ RSS](/packages/suven-flint-redis/feed)WikiDiscussions master Synced yesterday

READMEChangelogDependencies (4)Versions (4)Used By (0)

suven/flint-redis
=================

[](#suvenflint-redis)

[![Build Status](https://camo.githubusercontent.com/2353df2cf524aec8bd5624abf0d86b3e0d3c6b86c2b0daf63105e012c1cf0963/68747470733a2f2f7472617669732d63692e6f72672f537576656e2f666c696e7452656469732e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/Suven/flintRedis)[![Scrutinizer Code Quality](https://camo.githubusercontent.com/062e35d9ab6bbe57f9ebeae246c8a8237f2f5d3e4a47af5d7e7f6250e20caf66/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f537576656e2f666c696e7452656469732f6261646765732f7175616c6974792d73636f72652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/Suven/flintRedis/?branch=master)[![Code Coverage](https://camo.githubusercontent.com/41ecfa0df26b951c1d605d620dc2195ee77f7c5e9c101dec1670404a3404ddda/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f537576656e2f666c696e7452656469732f6261646765732f636f7665726167652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/Suven/flintRedis/?branch=master)

Super-thin and opinionated wrapper around [flintstone](https://github.com/fire015/flintstone) and [predis](https://github.com/nrk/predis).

Enables you to store multiple key-value collections with redis or the filesystem.

Background
----------

[](#background)

### Why would I want that?

[](#why-would-i-want-that)

If you are writing apps that need to cache data in collections, you would want to use some fast key-value-store such as redis or memcached. Unfortunally, redis is not always available - especially on shared hosters. In those scenarios, if you still need to cache stuff, the filesystem is often a better choice, then not to cache.

### Y U NO PSR-6?!

[](#y-u-no-psr-6)

There are plenty ready-to-use caching-adapters out there, which implement some common interfaces. Those adapters are often well tested, powerful and well maintained. They also might give you more freedom in choosing more providers. If you also need to offer support for memcached or db-caching, you should choose one of those.

That said, the power of this library comes from the fact that it's minimal and opinionated. It provides you with exactly two options for caching-providers and comes with all functions, those two providers share.

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

[](#installation)

`composer require suven/flint-redis`

Usage
-----

[](#usage)

```
use Suven\FlintRedis\FlintRedisCacheFactory;

if ($youWantToUseRedis) {
    FlintRedisCacheFactory::$strategy = FlintRedisCacheFactory::STRATEGY_REDIS;
    FlintRedisCacheFactory::$options = [
        "yourOptions" => "that you'd like to pass to predis"
    ];
}

if ($youWantToUseFlintstone) {
    FlintRedisCacheFactory::$strategy = FlintRedisCacheFactory::STRATEGY_FLINTSTONE;
    FlintRedisCacheFactory::$options = [
        "yourOptions" => "that you'd like to pass to flintstone"
    ];
}

// Get a new collection for settings
$settings = FlintRedisCacheFactory::create("settings");

// Set a value
$settings->set('target', 'worldDomination');
$settings->set('favNumber', 42);
$settings->set('someBool', true);
$settings->set('youCanStoreAnythingPHPcanSerialize', [
    'foo' => 'bar'
]);

// Get a value by key
$favNumber = $settings->get('favNumber');

// Get all values
$allSettings = $settings->getAll();

// Get all keys
$settingKeys = $settings->getKeys();

// Delete a value by key
$settings->delete('favNumber');

// Delete all settings
$settings->flush();
```

###  Health Score

25

—

LowBetter than 36% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity60

Established project with proven stability

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

Total

3

Last Release

3353d ago

Major Versions

v0.0.1 → v1.0-BETA2017-04-16

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/465894?v=4)[Sven Lückenbach](/maintainers/suven)[@Suven](https://github.com/Suven)

---

Top Contributors

[![Suven](https://avatars.githubusercontent.com/u/465894?v=4)](https://github.com/Suven "Suven (27 commits)")

---

Tags

cachingkey-valuephp-libraryredis

###  Code Quality

TestsPHPUnit

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/suven-flint-redis/health.svg)

```
[![Health](https://phpackages.com/badges/suven-flint-redis/health.svg)](https://phpackages.com/packages/suven-flint-redis)
```

###  Alternatives

[unopim/unopim

UnoPim Laravel PIM

10.5k2.2k](/packages/unopim-unopim)[rhubarbgroup/redis-cache

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

52699.8k1](/packages/rhubarbgroup-redis-cache)[symfony-bundles/redis-bundle

Symfony Redis Bundle

271.2M6](/packages/symfony-bundles-redis-bundle)[pdffiller/qless-php

PHP Bindings for qless

29113.7k1](/packages/pdffiller-qless-php)[millipress/millicache

WordPress Full-Page Cache based on Rules &amp; Flags. Delivers flexible, scalable caching workflows backed by Redis and ValKey in-memory stores.

712.0k2](/packages/millipress-millicache)

PHPackages © 2026

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