PHPackages                             iglocska/php-resque-ex - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Caching](/categories/caching)
4. /
5. iglocska/php-resque-ex

ActiveLibrary[Caching](/categories/caching)

iglocska/php-resque-ex
======================

Fork of wa0x6e's php-resque ex library for use in MISP, adding partial monolog 2.5.x support.

1.4.1(1y ago)134.7k—5.6%1MITPHPPHP &gt;=7.2.0

Since Aug 21Pushed 1y ago1 watchersCompare

[ Source](https://github.com/iglocska/php-resque-ex)[ Packagist](https://packagist.org/packages/iglocska/php-resque-ex)[ Docs](http://www.github.com/iglocska/php-resque-ex/)[ RSS](/packages/iglocska-php-resque-ex/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (2)Versions (29)Used By (1)

Php-Resque-ex: Resque for PHP [![Build Status](https://camo.githubusercontent.com/e63a470baf8115b8e03df22ba105ce377db8cc82ff354d9884b1c62b460cdf46/68747470733a2f2f7365637572652e7472617669732d63692e6f72672f7761307836652f7068702d7265737175652d65782e706e67)](http://travis-ci.org/wa0x6e/php-resque-ex)
==========================================================================================================================================================================================================================================================================================================

[](#php-resque-ex-resque-for-php-)

Resque is a Redis-backed library for creating background jobs, placing those jobs on multiple queues, and processing them later.

Background
----------

[](#background)

Php-Resque-Ex is a fork of [php-resque](https://github.com/chrisboulton/php-resque) by chrisboulton. See the [original README](https://github.com/chrisboulton/php-resque/blob/master/README.md) for more informations.

Additional features
-------------------

[](#additional-features)

This fork provides some additional features :

### Support of php-redis

[](#support-of-php-redis)

Autodetect and use [phpredis](https://github.com/nicolasff/phpredis) to connect to Redis if available. Redisent is used as fallback.

### Powerfull logging

[](#powerfull-logging)

Instead of piping STDOUT output to a file, you can log directly to a database, or send them elsewhere via a socket. We use [Monolog](https://github.com/Seldaek/monolog) to manage all the logging. See their documentation to see all the available handlers.

Log infos are augmented with more informations, and associated with a workers, a queue, and a job ID if any.

### Job creation delegation

[](#job-creation-delegation)

If Resque\_Job\_Creator class exists and is found by Resque, all jobs creation will be delegated to this class.

The best way to inject this class is to include it in you `APP_INCLUDE` file.

Class content is :

```
class Resque_Job_Creator
{
	public static function createJob($className, $args) {

		// $className is you job class name, the second arguments when enqueuing a job
		// $args are the arguments passed to your jobs

		// Instanciate your class, and return the instance

		return new $className();
	}
}
```

This is pretty useful when your autoloader can not load the class, like when classname doesn't match its filename. Some framework, like CakePHP, uses `PluginName.ClassName` convention for classname, and require special handling before loading.

### Failed jobs logs

[](#failed-jobs-logs)

You can easily retrieve logs for a failed jobs in the redis database, their keys are named after their job ID. Each failed log will expire after 2 weeks to save space.

### Command Line tool

[](#command-line-tool)

Fresque is shipped by default to manage your workers. See [Fresque Documentation](https://github.com/wa0x6e/Fresque) for usage.

Installation
------------

[](#installation)

Clone the git repo

```
$ git clone git://github.com/wa0x6e/php-resque-ex.git

```

`cd` into the folder you just cloned

```
$ cd ./php-resque-ex

```

Download Composer

```
$ curl -s https://getcomposer.org/installer | php

```

Install dependencies

```
$ php composer.phar install

```

#### Warning

[](#warning)

php-resque requires the pcntl php extension, not available on Windows platform. Composer installation will fail if you're trying to install this package on Windows machine. If you still want to continue with the installation at your own risk, execute the composer install command with the `--ignore-platform-reqs` option.

Usage
-----

[](#usage)

### Logging

[](#logging)

Use the same way as the original port, with additional ENV :

- `LOGHANDLER` : Specify the handler to use for logging (File, MongoDB, Socket, etc …). See [Monolog](https://github.com/Seldaek/monolog#handlers) doc for all available handlers. `LOGHANDLER` is the name of the handler, without the "Handler" part. To use CubeHandler, just type "Cube".
- `LOGHANDLERTARGET` : Information used by the handler to connect to the database. Depends on the type of loghandler. If it's the *RotatingFileHandler*, the target will be the filename. If it's CubeHandler, target will be a udp address. Refer to each Handler to see what type of argument their `__construct()` method requires.
- `LOGGING` : This environment variable must be set in order to enable logging via Monolog. i.e `LOGGING=1`

If one of these two environement variable is missing, it will default to *RotatingFile* Handler.

### Redis backend

[](#redis-backend)

- `REDIS_BACKEND` : hostname of your Redis database
- `REDIS_DATABASE` : To select another redis database (default 0)
- `REDIS_NAMESPACE` : To set a different namespace for the keys (default to *resque*)
- `REDIS_PASSWORD` : If your Redis backend needs authentication

Requirements
------------

[](#requirements)

- PHP 5.3+
- Redis 2.2+

Contributors
------------

[](#contributors)

- [chrisboulton](https://github.com/chrisboulton/php-resque) for the original port
- wa0x6e

###  Health Score

42

—

FairBetter than 90% of packages

Maintenance34

Infrequent updates — may be unmaintained

Popularity30

Limited adoption so far

Community22

Small or concentrated contributor base

Maturity69

Established project with proven stability

 Bus Factor1

Top contributor holds 64.1% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~183 days

Recently: every ~1031 days

Total

25

Last Release

620d ago

PHP version history (2 changes)1.0.0PHP &gt;=5.3.0

1.4.0PHP &gt;=7.2.0

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/3668672?v=4)[Andras Iklody](/maintainers/iglocska)[@iglocska](https://github.com/iglocska)

---

Top Contributors

[![wa0x6e](https://avatars.githubusercontent.com/u/495709?v=4)](https://github.com/wa0x6e "wa0x6e (109 commits)")[![chrisboulton](https://avatars.githubusercontent.com/u/98472?v=4)](https://github.com/chrisboulton "chrisboulton (10 commits)")[![mfauveau](https://avatars.githubusercontent.com/u/32339?v=4)](https://github.com/mfauveau "mfauveau (8 commits)")[![hoomanna](https://avatars.githubusercontent.com/u/5413073?v=4)](https://github.com/hoomanna "hoomanna (7 commits)")[![iglocska](https://avatars.githubusercontent.com/u/3668672?v=4)](https://github.com/iglocska "iglocska (6 commits)")[![hobodave](https://avatars.githubusercontent.com/u/12404?v=4)](https://github.com/hobodave "hobodave (4 commits)")[![kevburnsjr](https://avatars.githubusercontent.com/u/20638?v=4)](https://github.com/kevburnsjr "kevburnsjr (3 commits)")[![warezthebeef](https://avatars.githubusercontent.com/u/521746?v=4)](https://github.com/warezthebeef "warezthebeef (2 commits)")[![ebernhardson](https://avatars.githubusercontent.com/u/558434?v=4)](https://github.com/ebernhardson "ebernhardson (2 commits)")[![maetl](https://avatars.githubusercontent.com/u/24809?v=4)](https://github.com/maetl "maetl (2 commits)")[![patrickbajao](https://avatars.githubusercontent.com/u/383183?v=4)](https://github.com/patrickbajao "patrickbajao (2 commits)")[![pedroarnal](https://avatars.githubusercontent.com/u/860007?v=4)](https://github.com/pedroarnal "pedroarnal (2 commits)")[![d11wtq](https://avatars.githubusercontent.com/u/37948?v=4)](https://github.com/d11wtq "d11wtq (1 commits)")[![jjfrey](https://avatars.githubusercontent.com/u/799117?v=4)](https://github.com/jjfrey "jjfrey (1 commits)")[![jmathai](https://avatars.githubusercontent.com/u/6384?v=4)](https://github.com/jmathai "jmathai (1 commits)")[![brendo](https://avatars.githubusercontent.com/u/69268?v=4)](https://github.com/brendo "brendo (1 commits)")[![scragg0x](https://avatars.githubusercontent.com/u/222611?v=4)](https://github.com/scragg0x "scragg0x (1 commits)")[![bpdeployer](https://avatars.githubusercontent.com/u/19269451?v=4)](https://github.com/bpdeployer "bpdeployer (1 commits)")[![michaelmessig](https://avatars.githubusercontent.com/u/64106?v=4)](https://github.com/michaelmessig "michaelmessig (1 commits)")[![arbet](https://avatars.githubusercontent.com/u/1234119?v=4)](https://github.com/arbet "arbet (1 commits)")

---

Tags

phpredisqueuejobbackgroundresquemisp

### Embed Badge

![Health badge](/badges/iglocska-php-resque-ex/health.svg)

```
[![Health](https://phpackages.com/badges/iglocska-php-resque-ex/health.svg)](https://phpackages.com/packages/iglocska-php-resque-ex)
```

###  Alternatives

[mjphaynes/php-resque

Redis backed library for creating background jobs and processing them later.

228199.3k2](/packages/mjphaynes-php-resque)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
