Download the PHP package klsoft/yii3-swoole without Composer
On this page you can find all versions of the php package klsoft/yii3-swoole. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download klsoft/yii3-swoole
More information about klsoft/yii3-swoole
Files in klsoft/yii3-swoole
Package yii3-swoole
Short Description The package provides the Swoole HTTP server for the Yii 3 application
License MIT
Homepage https://github.com/klsoft-web/yii3-swoole
Informations about the package yii3-swoole
YII3-SWOOLE
The package provides the Swoole HTTP server for the Yii 3 application.
Requirement
- PHP 8.2 or higher.
- Swoole PHP extension 6.2.0 or higher.
Installation
How to use
Configure the resetting of service states.
For web applications that use AssetManager, add the following to the config/web/di/application.php file:
Start the Swoole HTTP server:
Start the Swoole HTTP server using the specified options:
Restart the Swoole HTTP server:
Restart the Swoole HTTP server worker processes:
Shutdown the Swoole HTTP server:
Configuring the Swoole HTTP server.
Add the Swoole HTTP server settings to the config/web/params.php file and then restart the server:
Example:
Enable SSL:
Configuring the SwooleRequestHandlerInterface.
Configure your own version of the SwooleRequestHandlerInterface in the config/web/di/application.php file:
Use cron to start the Swoole HTTP server automatically.
Edit the crontab file:
Add the following line:
All versions of yii3-swoole with dependencies
yiisoft/yii-console Version ^2.4.2
yiisoft/yii-runner Version ^2.2
ext-swoole Version >=6.2