Download the PHP package kylin987/webman-redis-queue-drain without Composer

On this page you can find all versions of the php package kylin987/webman-redis-queue-drain. 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 webman-redis-queue-drain

webman-redis-queue-drain

在 Webman reload 前暂停 webman/redis-queue 领取新任务,同时允许已经领取的任务继续 执行。暂停状态只读取 Pod 本地文件,不使用 Redis 状态键或计数器。

支持:

安装

将项目 Redis Queue 进程配置中的 handler 改为:

包不会覆盖项目原有的队列进程数量和消费者目录配置。

配置

健康检查与部署脚本必须使用相同的 reload_file。可以通过以下命令读取项目实际生效的 路径:

文件存在时,队列 Worker 不再发起新的 BRPOP;文件删除后恢复消费。标志出现前已经 发出的 BRPOP 最多可能返回一条任务,该任务会正常执行一次。

部署约定

部署脚本应在 reload 前创建 reload_file,等待当前任务排空一段时间后执行普通 php start.php reload,并在 reload 后继续保留该文件一段时间。删除文件后,新队列 Worker 才会恢复领取任务。

Workerman 会逐个 reload Worker,固定等待不能严格证明所有旧 Worker 都已经退出。若 业务要求严格的完成确认,应在部署系统中增加 Workerman master 完成握手;本包本身只 负责暂停与恢复队列拉取。

Kubernetes 参考脚本

包内提供了一个保持简单职责的参考脚本:

脚本会按照 Pod 顺序执行:创建 reload_file、等待 readinessProbe 摘除 Pod、执行 Webman 自带的 php start.php reload、删除 reload_file。插件不负责发起 reload。

使用前请确认:

脚本默认使用 /dev/shm/reloading。若项目修改了插件的 reload_file,执行脚本时应设置 相同的环境变量:


All versions of webman-redis-queue-drain with dependencies

PHP Build Version
Package Version
Requires php Version >=7.2
webman/redis-queue Version ^1.2 || ^2.1
workerman/redis-queue Version >=1.1 <1.3
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 kylin987/webman-redis-queue-drain contains the following files

Loading the files please wait ...