承接 shonm/resque-bundle 相关项目开发

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

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

shonm/resque-bundle

Composer 安装命令:

composer require shonm/resque-bundle

包简介

Symfony2 bundle for Resque via php-resque

README 文档

README

Create a Job

// src/Acme/ResqueBundle/Job/TestJob.php
namespace Acme\ResqueBundle\Job;

class HelloWorldJob
{
    public function perform ()
    {
        fwrite(STDOUT, "Hello " . $this->args['hello'] . "!\n");
    }
}

Post your Job

$container->get('resque')->add('Acme\ResqueBundle\Job\HelloWorldJob', 'queuename', array('hello' => 'world'));

Hire a Worker

app/console resque:worker:start queuename

Party!

Best Practices

  1. Jobs should be small and simple
  2. Workers should be idempotent and transactional
  3. Design for concurrency - use connection pooling

Development & Testing

$ composer install --dev
$ bin/phpunit

统计信息

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

GitHub 信息

  • Stars: 12
  • Watchers: 1
  • Forks: 6
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2012-12-14