PHPackages                             godfery/php\_multithread - 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. godfery/php\_multithread

ActiveLibrary

godfery/php\_multithread
========================

iPHP library to handle multi-threading

0.01(8y ago)123PHPPHP &gt;=5.3.0

Since Aug 29Pushed 8y ago1 watchersCompare

[ Source](https://github.com/godfery/multithread)[ Packagist](https://packagist.org/packages/godfery/php_multithread)[ RSS](/packages/godfery-php-multithread/feed)WikiDiscussions master Synced 2mo ago

READMEChangelog (1)DependenciesVersions (2)Used By (0)

Authors &amp; contact
---------------------

[](#authors--contact)

godfery -

Documentation and download
--------------------------

[](#documentation-and-download)

This software refer to on github at : -

Description
-----------

[](#description)

This library provides a lightweight / simple PHP Oriented Object classe to handle multi-threading. Check the sample folder for examples on how to use it. This library requires to have the pcntl () extension installed and it will only work with unix distributions.

Setup
-----

[](#setup)

You can use composer to use this library.

```
{
    "require": {
		"godfery/multithread": "*"
    }
}

```

Usage
-----

[](#usage)

This client does not rely or depend on any framework and it should be fairly easy to integrate with your own code. You can use composer or your own custom autoloader.

The sample folder contains example on how to use this library.

Example
-------

[](#example)

### Multi-threading a simple task

[](#multi-threading-a-simple-task)

```
require(__DIR__ . '/../vendor/autoload.php');

$maxThreads = 5;
echo 'Example of the multi-thread manager with ' . $maxThreads . ' threads' . PHP_EOL . PHP_EOL;
$params = array();
$exampleTask = new Threading\Task\Example($params);
$multithreadManager = new Threading\Multiple();

$cpt = 0;
while (++$cpt start($exampleTask);
}

```

Will provide following output :

```
Example of the multi-thread manager with 5 threads

[Pid:23447] Task executed at 2015-04-03 14:49:18
[Pid:23448] Task executed at 2015-04-03 14:49:18
[Pid:23449] Task executed at 2015-04-03 14:49:18
[Pid:23450] Task executed at 2015-04-03 14:49:18
[Pid:23451] Task executed at 2015-04-03 14:49:18
[Pid:23452] Task executed at 2015-04-03 14:49:19
[Pid:23454] Task executed at 2015-04-03 14:49:19
[Pid:23453] Task executed at 2015-04-03 14:49:19
[Pid:23455] Task executed at 2015-04-03 14:49:19
[Pid:23456] Task executed at 2015-04-03 14:49:19
[Pid:23457] Task executed at 2015-04-03 14:49:20
[Pid:23458] Task executed at 2015-04-03 14:49:20
[Pid:23459] Task executed at 2015-04-03 14:49:20
[Pid:23460] Task executed at 2015-04-03 14:49:20
[Pid:23461] Task executed at 2015-04-03 14:49:20
[Pid:23463] Task executed at 2015-04-03 14:49:21
[Pid:23462] Task executed at 2015-04-03 14:49:21
[Pid:23464] Task executed at 2015-04-03 14:49:21
[Pid:23465] Task executed at 2015-04-03 14:49:21
[Pid:23466] Task executed at 2015-04-03 14:49:21
[Pid:23467] Task executed at 2015-04-03 14:49:22
[Pid:23468] Task executed at 2015-04-03 14:49:22
[Pid:23470] Task executed at 2015-04-03 14:49:22
[Pid:23469] Task executed at 2015-04-03 14:49:22
[Pid:23471] Task executed at 2015-04-03 14:49:22
[Pid:23472] Task executed at 2015-04-03 14:49:23
[Pid:23473] Task executed at 2015-04-03 14:49:23
[Pid:23474] Task executed at 2015-04-03 14:49:23
[Pid:23475] Task executed at 2015-04-03 14:49:23
[Pid:23476] Task executed at 2015-04-03 14:49:23

```

###  Health Score

23

—

LowBetter than 27% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity48

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

Unknown

Total

1

Last Release

3181d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/bf3e788b13a5a205c09a5b28e8b016d9e3b6c1dd702d6b956384733e239bf3ed?d=identicon)[godfery](/maintainers/godfery)

---

Top Contributors

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

### Embed Badge

![Health badge](/badges/godfery-php-multithread/health.svg)

```
[![Health](https://phpackages.com/badges/godfery-php-multithread/health.svg)](https://phpackages.com/packages/godfery-php-multithread)
```

PHPackages © 2026

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