PHPackages                             symfony-bundles/fork - 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. symfony-bundles/fork

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

symfony-bundles/fork
====================

SymfonyBundles Fork Library

v3.5.0(8y ago)178.0k1MITPHPPHP ^7.1.3

Since Jun 7Pushed 8y ago4 watchersCompare

[ Source](https://github.com/symfony-bundles/fork)[ Packagist](https://packagist.org/packages/symfony-bundles/fork)[ Docs](https://github.com/symfony-bundles/fork)[ RSS](/packages/symfony-bundles-fork/feed)WikiDiscussions master Synced 1w ago

READMEChangelog (10)Dependencies (2)Versions (15)Used By (0)

SymfonyBundles Fork Library
===========================

[](#symfonybundles-fork-library)

[![SensioLabsInsight](https://camo.githubusercontent.com/2906c6359075d3402b68cb507ddf7337d93ef35dc1b48ea5bd395c02fff6b2be/68747470733a2f2f696e73696768742e73656e73696f6c6162732e636f6d2f70726f6a656374732f38333633396139632d383831622d343733382d623365392d6561333034363030633930302f6269672e706e67)](https://insight.sensiolabs.com/projects/83639a9c-881b-4738-b3e9-ea304600c900)

[![Build Status](https://camo.githubusercontent.com/1e9882bf34f1d2d655d1adcfac7b55ff20f4a53c3d245fceb41974b713811b30/68747470733a2f2f7472617669732d63692e6f72672f73796d666f6e792d62756e646c65732f666f726b2e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/symfony-bundles/fork)[![Scrutinizer Code Quality](https://camo.githubusercontent.com/fe3d72571de84cc9edcc9eaac48efad7f214653f594b211db27baa51b3b318dd/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f73796d666f6e792d62756e646c65732f666f726b2f6261646765732f7175616c6974792d73636f72652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/symfony-bundles/fork/?branch=master)[![Code Coverage](https://camo.githubusercontent.com/40460f6bb8f1945bf945f682c79f3c32e2234fbd4e48135f7dd8011201358073/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f73796d666f6e792d62756e646c65732f666f726b2f6261646765732f636f7665726167652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/symfony-bundles/fork/?branch=master)[![Total Downloads](https://camo.githubusercontent.com/2e29012a94bfe364d5e19854fa12047313db5e076cbc54bcd2cba39d79067757/68747470733a2f2f706f7365722e707567782e6f72672f73796d666f6e792d62756e646c65732f666f726b2f646f776e6c6f616473)](https://packagist.org/packages/symfony-bundles/fork)[![Latest Stable Version](https://camo.githubusercontent.com/bd7e37b35dc3825ffd5652295da65edf109be1c53d2de3ea1b2fb671654a0a42/68747470733a2f2f706f7365722e707567782e6f72672f73796d666f6e792d62756e646c65732f666f726b2f762f737461626c65)](https://packagist.org/packages/symfony-bundles/fork)[![License](https://camo.githubusercontent.com/f10a59f3788b2a87c0f10729d8afe7317d9b1039b1f53a9b9228b0f346f55e7c/68747470733a2f2f706f7365722e707567782e6f72672f73796d666f6e792d62756e646c65732f666f726b2f6c6963656e7365)](https://github.com/symfony-bundles/fork/blob/master/LICENSE)

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

[](#installation)

Install the library with composer:

```
composer require symfony-bundles/fork
```

How to use (only cli-mode)
--------------------------

[](#how-to-use-only-cli-mode)

Create the fork service:

```
use SymfonyBundles\Fork;

$fork = new Fork\Fork();
```

Create a task that implements an interface `SymfonyBundles\Fork\TaskInterface`. For example:

```
namespace AppBundle\Task;

use SymfonyBundles\Fork\TaskInterface;

class DemoTask implements TaskInterface
{
    public function execute()
    {
        echo "Hello World!\n";
    }
}
```

Now that the task is created, you can execute her in a plurality processes:

```
use AppBundle\Task\DemoTask;

$task = new DemoTask();

$fork->attach($task)->run(4)->wait(); // 4 - this is number of subprocesses
```

And another example:

```
$task1 = new DemoTask();
$task2 = new DemoTask();
$task3 = new DemoTask();

$fork->attach($task1)->attach($task2)->attach($task3);
$fork->run(); // by default, the optimal number of subprocesses will be determined
$fork->wait();
```

If you call method `wait`, the current process (main) will wait while all child processes will be finished.

###  Health Score

35

—

LowBetter than 80% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity30

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity66

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

Recently: every ~1 days

Total

14

Last Release

3003d ago

Major Versions

v1.0.2 → v2.0.02018-02-12

v2.0.0 → v3.0.02018-02-12

PHP version history (2 changes)v1.0.0PHP &gt;=5.6

v2.0.0PHP ^7.1.3

### Community

Maintainers

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

---

Top Contributors

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

---

Tags

forkphpprocesssymfonysymfony-bundlesymfonylibraryprocessforkflowThreadmultiprocesses

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/symfony-bundles-fork/health.svg)

```
[![Health](https://phpackages.com/badges/symfony-bundles-fork/health.svg)](https://phpackages.com/packages/symfony-bundles-fork)
```

###  Alternatives

[arara/process

Provides a better API to work with processes on Unix-like systems

16861.7k2](/packages/arara-process)[lifo/php-ipc

Simple PHP Inter Process Communication (IPC) library

285.5k](/packages/lifo-php-ipc)

PHPackages © 2026

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