PHPackages                             flytachi/winter-thread - 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. [Queues &amp; Workers](/categories/queues)
4. /
5. flytachi/winter-thread

ActiveLibrary[Queues &amp; Workers](/categories/queues)

flytachi/winter-thread
======================

Object-oriented background process control for PHP — a Java-like threading model over OS processes.

v1.3.5(2d ago)2458↓64.4%1MITPHPPHP &gt;=8.1

Since Dec 18Pushed 2mo agoCompare

[ Source](https://github.com/Flytachi/winter-thread)[ Packagist](https://packagist.org/packages/flytachi/winter-thread)[ Docs](https://winterframe.net)[ RSS](/packages/flytachi-winter-thread/feed)WikiDiscussions main Synced yesterday

READMEChangelog (4)Dependencies (8)Versions (14)Used By (1)

Winter Thread: A Modern Process Control Library for PHP
=======================================================

[](#winter-thread-a-modern-process-control-library-for-php)

[![Latest Version on Packagist](https://camo.githubusercontent.com/52f623912eb6fb984078619d594d7073a678b46473e2824d18a2207c3acb60a6/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f666c7974616368692f77696e7465722d7468726561642e737667)](https://packagist.org/packages/flytachi/winter-thread)[![PHP Version Require](https://camo.githubusercontent.com/c0a3d91a7f0418b5596220865a9810548d5cae251bd6ff5fdf041413a58428d7/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f7068702d762f666c7974616368692f77696e7465722d7468726561642e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/flytachi/winter-thread)[![Software License](https://camo.githubusercontent.com/074b89bca64d3edc93a1db6c7e3b1636b874540ba91d66367c0e5e354c56d0ea/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e737667)](LICENSE)

**Winter Thread** provides a clean, object-oriented API for running and controlling background processes in PHP, simulating a traditional threading model for parallel and long-running tasks.

It abstracts away the complexities of `proc_open` and POSIX signals into a powerful and easy-to-use interface.

Key Features
------------

[](#key-features)

- **Fluent, Object-Oriented API**: Manage background processes as objects.
- **Full Process Control**: `start()`, `join()`, `pause()`, `resume()`, `terminate()`, and `kill()`.
- **Advanced Process Naming**: Identify your processes easily with namespaces, names, and tags.
- **Safe by Default**: Output goes to `/dev/null` by default — no Broken pipe risk for fire-and-forget jobs.
- **Swoole / Event-Loop Compatible**: Three payload delivery modes (`PIPE`, `TEMP_FILE`, `SHM`) to avoid fd corruption under `SWOOLE_HOOK_ALL`.
- **Extensible**: Easily override the runner script for deep framework integration.
- **Java-like API**: Familiar method names like `isAlive()` and `join()` for an easy learning curve.

Requirements
------------

[](#requirements)

- PHP &gt;= 8.1
- `ext-pcntl`
- `ext-posix`
- `opis/closure` ^4.5 (required; enables safe serialization of anonymous classes and closures)

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

[](#installation)

```
composer require flytachi/winter-thread
```

Quick Start
-----------

[](#quick-start)

```
