Download the PHP package jcbowen/yiiswoole without Composer

On this page you can find all versions of the php package jcbowen/yiiswoole. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package yiiswoole

yiiSwoole

介绍

Yii2 + Swoole4

目前实现了websocket服务器,同时支持了高性能共享内存Table的使用

不兼容说明

使用了usleep,所以不兼容win环境

前提

服务器中需要安装swoole4

(如果是宝塔搭建的环境,直接在使用的php版本中安装swoole4扩展)

由于某些跟踪调试的 PHP 扩展大量使用了全局变量,可能会导致 Swoole 协程发生崩溃。请关闭以下相关扩展:

安装教程

composer执行

或者在 composer.json 加入

配置说明

在console/config/main.php的controllerMap中加入配置

使用

运行说明

websocket客户端向服务器发送json字符串,如:
如果握手的时候,携带了目录路径,该路径将会作为route缓存起来;请求中如果携带了route字段,则替换缓存中的route
通过执行方法,可以读取上下文中缓存的信息;
通过执行方法,可以读取上下文中缓存的get数据;
其中server和frame会被缓存到中;
接收到的json会被转为数组后缓存到中;
携带的目录代表的是监听到动作后转发到哪个路由(由于通过console运行的进程,所以这里的路由指的是console里的路由)。
总结:jcbowen/yiiswoole插件会在websocket触发onmessage时,根据route调用对应的控制器方法,并将websocket服务和接收到数据分别存放到与中;

在控制器方法中使用


All versions of yiiswoole with dependencies

PHP Build Version
Package Version
Requires php Version >=7.4
yiisoft/yii2 Version ^2.0
ext-posix Version *
ext-json Version *
jcbowen/jcbase-yii2 Version ^0.x-dev || >=0.30.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package jcbowen/yiiswoole contains the following files

Loading the files please wait ...