PHPackages                             sproutwp/sprout\_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. sproutwp/sprout\_cache

ActiveLibrary[Caching](/categories/caching)

sproutwp/sprout\_cache
======================

A smart cache graph system for WordPress, as used by the Sprout Framework

05[1 issues](https://github.com/sproutwp/sprout_cache/issues)PHP

Since Jun 12Pushed 7y agoCompare

[ Source](https://github.com/sproutwp/sprout_cache)[ Packagist](https://packagist.org/packages/sproutwp/sprout_cache)[ RSS](/packages/sproutwp-sprout-cache/feed)WikiDiscussions master Synced 2w ago

READMEChangelogDependenciesVersions (1)Used By (0)

Sprout Cache
============

[](#sprout-cache)

*Make sure you understand the trade-off between executing code &amp; hitting the database for a transient. It might seem appealing to store the result of code execution in the database and it might seem like an optimization to only have it deleted when it needs to and not on a timer, but it might not be worth it.*

A smart graph caching system that can be used to clear transients on certain actions or based on logic, not just on time. Often used together with the SproutServices to output data from private parts of a system that need to be re-generated every time the authorized user re-accesses the resource that generated the data to begin with.

Use Cases
---------

[](#use-cases)

#### Delete a transient when a specific post updates.

[](#delete-a-transient-when-a-specific-post-updates)

Often times, instead of generating a lot of things for a post page, for example a recipe or a gallery that requires heavy computation in terms of retrieving remote images and such, we can transient it all. But do we want it to *ever* expire? Yes and no. We'd like for it to not expire based on time, but rather action, as such, you will be saving your transient as `gallery_transient` and declare that you'd want it cleared when the post with ID `48` is deletes, as such, the hook you're looking for to use as a "clear point" is `save_post` and check if the ID corresponds to what you need.

#### Get output data from restricted areas.

[](#get-output-data-from-restricted-areas)

Assume non-authorized others want to see the output of something, but you wouldn't like to give them access to the module itself since it's dangerous for them to be able to interact with it - save the output and update it every time an authorized user re-accesses the said resource that generated the output.

###  Health Score

19

—

LowBetter than 9% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity37

Early-stage or recently created project

 Bus Factor1

Top contributor holds 55.6% 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.

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/51598561?v=4)[sproutwp](/maintainers/sproutwp)[@sproutwp](https://github.com/sproutwp)

---

Top Contributors

[![sproutwp](https://avatars.githubusercontent.com/u/51598561?v=4)](https://github.com/sproutwp "sproutwp (5 commits)")[![themeflame](https://avatars.githubusercontent.com/u/9643236?v=4)](https://github.com/themeflame "themeflame (4 commits)")

### Embed Badge

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

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

###  Alternatives

[beryllium/cachebundle

Provides an interface to Memcache for Symfony2 applications

32136.0k](/packages/beryllium-cachebundle)

PHPackages © 2026

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