承接 ronanchilvers/silex-queue-beanstalkd 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

ronanchilvers/silex-queue-beanstalkd

Composer 安装命令:

composer require ronanchilvers/silex-queue-beanstalkd

包简介

Simple queue mechanism for silex using beanstalkd

README 文档

README

This is a simple queue mechanism for Silex using Beanstalkd as the backend.

Installation

Installation using composer:

composer require ronanchilvers\silex-queue-beanstalkd

We're assuming that you have an accessible Beanstalkd instance running somewhere and that you know its network address.

Configuration

To use the queue service you need to register the provider like so:

$app->register(new Ronanchilvers\Silex\Queue\QueueProvider());

By default this assumes that Beanstalkd is running on the default port (11300) on localhost.

There are a few configuration directives that you can use to get the queue service working. You can pass these in using the normal Silex way like this:

$app->register(new Ronanchilvers\Silex\Queue\QueueProvider(), [
    'queue.options' => [
        'host' => '1.2.3.4'
    ]
]);

The available configuration keys are:

  • host : Beanstalkd host (default localhost)
  • port : Beanstalkd port (default 11300)
  • timeout : Timeout for Beanstalkd connection (default 2 seconds). This option is passed directly through to Pheanstalk.
  • persistent : Use a persistent connection to Beanstalkd or not (default false). This option is passed directly through to Pheanstalk.
  • default.queue : default queue to push / pull to / from. The queue can be overridden at publish / consume time.
  • max.iterations : maximum iterations a worker does when using the queue:consume CLI command before exiting

Consume Command

A simple consume command for use with symfony/console is provided. The command requires the knplabs/console-service-provider package as it needs access to the Application object. To use it you can do something like this:

$console->add(new Ronanchilvers\Silex\Queue\Console\Command\ConsumeCommand());

which will add a queue:consume command to the console application.

统计信息

  • 总下载量: 183
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2018-01-15

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固