PHPackages                             codeages/token-bucket - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. codeages/token-bucket

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

codeages/token-bucket
=====================

Token Bucket.

v0.1.0(9y ago)1251MITPHP

Since Aug 8Pushed 9y ago3 watchersCompare

[ Source](https://github.com/codeages/token-bucket)[ Packagist](https://packagist.org/packages/codeages/token-bucket)[ RSS](/packages/codeages-token-bucket/feed)WikiDiscussions master Synced 4w ago

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

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

[](#installation)

- use composer ```
    composer require codeages/token-bucket

    ```

notice
------

[](#notice)

- add redis mux key support for concurrency
- remove the db support

Usage
-----

[](#usage)

- example ```
    $tokens = 30; //the bucket capacity
    $rates = 10; //recover tokens per second
    $consume = 10; //consume tokens
    $key = "test"; //bucket name

    $redis = new \Redis();
    $redis->connect('127.0.0.1', 6379, 1);
    $driver = new RedisDriver("test", $redis);
    $tokenBucket = new TokenBucket($tokens, $rates, $name);
    $tokenBucket->setDriver($driver)->watch();

    $tokenBucket->consume($consume);

    ```

###  Health Score

26

—

LowBetter than 41% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity9

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity54

Maturing project, gaining track record

 Bus Factor1

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

Unknown

Total

1

Last Release

3488d ago

### Community

Maintainers

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

---

Top Contributors

[![findsomething](https://avatars.githubusercontent.com/u/3618101?v=4)](https://github.com/findsomething "findsomething (5 commits)")[![lileiseven](https://avatars.githubusercontent.com/u/94609?v=4)](https://github.com/lileiseven "lileiseven (2 commits)")

### Embed Badge

![Health badge](/badges/codeages-token-bucket/health.svg)

```
[![Health](https://phpackages.com/badges/codeages-token-bucket/health.svg)](https://phpackages.com/packages/codeages-token-bucket)
```

###  Alternatives

[flow-php/flow

PHP ETL - Extract Transform Load - Data processing framework

85036.3k](/packages/flow-php-flow)[ecotone/ecotone

Enterprise architecture layer for Laravel and Symfony — CQRS, Event Sourcing, Durable Workflows (Sagas, Orchestrators), Projections, and Outbox messaging via PHP attributes.

564576.7k48](/packages/ecotone-ecotone)[shopware/core

Shopware platform is the core for all Shopware ecommerce products.

585.6M559](/packages/shopware-core)[typo3/cms-redirects

TYPO3 CMS Redirects - Create manual redirects, list existing redirects and automatically createredirects on slug changes.

167.4M78](/packages/typo3-cms-redirects)[elgg/elgg

Elgg is an award-winning social networking engine, delivering the building blocks that enable businesses, schools, universities and associations to create their own fully-featured social networks and applications.

1.7k16.2k56](/packages/elgg-elgg)[metamodels/core

MetaModels core

10156.4k68](/packages/metamodels-core)

PHPackages © 2026

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