PHPackages                             zerai/openswoole-runtime - 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. zerai/openswoole-runtime

ActiveLibrary

zerai/openswoole-runtime
========================

A openswoole runtime component.

0.1.0(3y ago)111.3kMITPHPPHP &gt;=8.0.5

Since Dec 30Pushed 3y ago1 watchersCompare

[ Source](https://github.com/zerai/openswoole-runtime)[ Packagist](https://packagist.org/packages/zerai/openswoole-runtime)[ Docs](https://github.com/zerai/openswoole-runtime)[ RSS](/packages/zerai-openswoole-runtime/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (1)Dependencies (8)Versions (2)Used By (0)

OpenSwoole Runtime
==================

[](#openswoole-runtime)

A runtime for [OpenSwoole](https://openswoole.com/).

If you are new to the Symfony Runtime component, read more in the [main readme](https://github.com/php-runtime/runtime).

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

[](#installation)

```
composer require zerai/openswoole-runtime

```

Usage
-----

[](#usage)

Define the environment variable `APP_RUNTIME` for your application.

```
APP_RUNTIME=Zerai\OpenSwoole\Runtime

```

### Pure PHP

[](#pure-php)

```
// public/index.php

use OpenSwoole\Http\Request;
use OpenSwoole\Http\Response;

require_once dirname(__DIR__).'/vendor/autoload_runtime.php';

return function () {
    return function (Request $request, Response $response) {
        $response->header("Content-Type", "text/plain");
        $response->end("Hello World\n");
    };
};
```

### Symfony

[](#symfony)

```
// public/index.php

use App\Kernel;

require_once dirname(__DIR__).'/vendor/autoload_runtime.php';

return function (array $context) {
    return new Kernel($context['APP_ENV'], (bool) $context['APP_DEBUG']);
};
```

Using Options
-------------

[](#using-options)

You can define some configurations using Symfony's Runtime `APP_RUNTIME_OPTIONS` API.

OptionDescriptionDefault`host`The host where the server should binds to (precedes `SWOOLE_HOST` environment variable)`127.0.0.1``port`The port where the server should be listing (precedes `SWOOLE_PORT` environment variable)`8000``mode`Swoole's server mode (precedes `SWOOLE_MODE` environment variable)`SWOOLE_PROCESS``hot_reload`Enable server hot reload mode (precedes `SWOOLE_HOT_RELOAD` environment variable). Require server mode as SWOOLE\_PROCESS`0``settings`All Swoole's server settings ()`[]````
// public/index.php

use App\Kernel;

$_SERVER['APP_RUNTIME_OPTIONS'] = [
    'host' => '0.0.0.0',
    'port' => 9501,
    'mode' => SWOOLE_PROCESS,
    'hot-reload' => false,
    'settings' => [
        \Swoole\Constant::OPTION_WORKER_NUM => 2,
        \Swoole\Constant::OPTION_ENABLE_STATIC_HANDLER => true,
        \Swoole\Constant::OPTION_DOCUMENT_ROOT => dirname(__DIR__).'/public'
    ],
];

require_once dirname(__DIR__).'/vendor/autoload_runtime.php';

return function (array $context) {
    return new Kernel($context['APP_ENV'], (bool) $context['APP_DEBUG']);
};
```

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity22

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity40

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

1234d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/7d51ae970b2a5a1cee867a4426c457841fd61409077b8182332b4ee34c232e0e?d=identicon)[teclaizerai](/maintainers/teclaizerai)

---

Top Contributors

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

---

Tags

openswoolesymfony runtime

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/zerai-openswoole-runtime/health.svg)

```
[![Health](https://phpackages.com/badges/zerai-openswoole-runtime/health.svg)](https://phpackages.com/packages/zerai-openswoole-runtime)
```

###  Alternatives

[veewee/xml

XML without worries

1835.9M29](/packages/veewee-xml)[php-soap/wsdl-reader

A WSDL reader in PHP

212.3M9](/packages/php-soap-wsdl-reader)[phpro/http-tools

HTTP tools for developing more consistent HTTP implementations.

28137.8k](/packages/phpro-http-tools)[openswoole/core

Openswoole core library

181.1M32](/packages/openswoole-core)[swoole-bundle/swoole-bundle

Open/Swoole Symfony Bundle

6650.4k](/packages/swoole-bundle-swoole-bundle)[open-telemetry/context-swoole

Async Swoole/OpenSwoole context implementation for OpenTelemetry PHP.

1233.2k5](/packages/open-telemetry-context-swoole)

PHPackages © 2026

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