PHPackages                             uecode/qpush-bundle - 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. [Queues &amp; Workers](/categories/queues)
4. /
5. uecode/qpush-bundle

ActiveLibrary[Queues &amp; Workers](/categories/queues)

uecode/qpush-bundle
===================

Asynchronous processing for Symfony using Push Queues

3.0.2(7y ago)1682.4M↓12.3%54[9 issues](https://github.com/uecode/qpush-bundle/issues)[1 PRs](https://github.com/uecode/qpush-bundle/pulls)2Apache-2.0PHPPHP &gt;=5.6.0

Since Feb 5Pushed 7y ago9 watchersCompare

[ Source](https://github.com/uecode/qpush-bundle)[ Packagist](https://packagist.org/packages/uecode/qpush-bundle)[ Docs](https://github.com/uecode/qpush-bundle)[ RSS](/packages/uecode-qpush-bundle/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (14)Versions (36)Used By (2)

QPush - Symfony2 Push Queue Bundle
==================================

[](#qpush---symfony2-push-queue-bundle)

[![Build Status](https://camo.githubusercontent.com/d5466ecc0c3962567325e834789d1fa921f91141fb8f443a6ff093af72cc0a2a/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f7565636f64652f71707573682d62756e646c652f6d61737465722e7376673f7374796c653d666c61742d737175617265)](https://travis-ci.org/uecode/qpush-bundle)[![Quality Score](https://camo.githubusercontent.com/72b678e9e815963feff1e4b17a6d1c0a540b823c56d5b94018463a27cdf6460e/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f672f7565636f64652f71707573682d62756e646c652e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/uecode/qpush-bundle/)[![Code Coverage](https://camo.githubusercontent.com/e29f4452a2dad9de711ad00ba4a00edda5c8dc8077c1bb56e3e7d6fb11560d9a/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f636f7665726167652f672f7565636f64652f71707573682d62756e646c652e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/uecode/qpush-bundle/)[![Total Downloads](https://camo.githubusercontent.com/606b11f6bd748e3ddd3183c511a171531fd94df3a5a02f6145d6f99c3ce6f837/687474703a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f7565636f64652f71707573682d62756e646c652e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/uecode/qpush-bundle)

Overview
--------

[](#overview)

This bundle allows you to easily consume messages from Push Queues by simply tagging your services and relying on Symfony's event dispatcher - without needing to run a daemon or background process to continuously poll your queue.

**Full Documentation:** [qpush-bundle.readthedocs.org](http://qpush-bundle.rtfd.org)

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

[](#installation)

#### The bundle should be installed through composer.

[](#the-bundle-should-be-installed-through-composer)

```
composer require uecode/qpush-bundle

```

#### Update AppKernel.php of your Symfony Application

[](#update-appkernelphp-of-your-symfony-application)

Add the `UecodeQPushBundle` to your kernel bootstrap sequence, in the `$bundles`array.

```
public function registerBundles()
{
    $bundles = array(
        // ...
        new Uecode\Bundle\QPushBundle\UecodeQPushBundle(),
    );

    return $bundles;
}
```

Basic Configuration:
--------------------

[](#basic-configuration)

Here is a basic configuration that would create a push queue called `my_queue_name` using AWS or IronMQ. You can read about the supported providers and provider options in the [full documentation](http://qpush-bundle.rtfd.org).

###### Example

[](#example)

```
#app/config.yml

uecode_qpush:
    providers:
        ironmq:
            token:      YOUR_IRON_MQ_TOKEN_HERE
            project_id: YOUR_IRON_MQ_PROJECT_ID_HERE
        aws:
            key:    YOUR_AWS_KEY_HERE
            secret: YOUR_AWS_SECRET_HERE
            region: YOUR_AWS_REGION_HERE
    queues:
        my_queue_key:
            provider: ironmq #or aws
            options:
                queue_name: my_queue_name #optional. the queue name used on the provider
                push_notifications: true
                subscribers:
                    - { endpoint: http://example.com/qpush, protocol: http }
```

You may exclude aws key and secret to default to IAM role on the EC2 machine.

Publishing messages to your Queue
---------------------------------

[](#publishing-messages-to-your-queue)

Publishing messages is simple - fetch the registered Provider service from the container and call the `publish` method on the respective queue.

This bundle stores your messages as a json object and the publish method expects an array, typically associative.

###### Example

[](#example-1)

```
// src/My/Bundle/ExampleBundle/Controller/MyController.php

public function publishAction()
{
    $message = ['foo' => 'bar'];

    // fetch your provider service from the container
    $this->get('uecode_qpush')->get('my_queue_key')->publish($message);

    // you can also fetch it directly
    $this->get('uecode_qpush.my_queue_key')->publish($message);
}
```

Working with messages from your Queue
-------------------------------------

[](#working-with-messages-from-your-queue)

When a message hits your application, this bundle will dispatch a `MessageEvent`which can be handled by your services. You need to tag your services to handle these events.

###### Example

[](#example-2)

```
services:
    my_example_service:
    	class: My\Bundle\ExampleBundle\Service\ExampleService
    	tags:
    		- { name: uecode_qpush.event_listener, event: my_queue_key.message_received, method: onMessageReceived }
```

###### Example

[](#example-3)

```
// src/My/Bundle/ExampleBundle/Service/ExampleService.php

use Uecode\Bundle\QPushBundle\Event\MessageEvent;

public function onMessageReceived(MessageEvent $event)
{
    $queue_name = $event->getQueueName();
    $message    = $event->getMessage();

    // do some processing
}
```

The `Message` objects contain the provider specific message id, a message body, and a collection of provider specific metadata.

These properties are accessible through simple getters from the message object.

###### Example

[](#example-4)

```
// src/My/Bundle/ExampleBundle/Service/ExampleService.php

use Uecode\Bundle\QPushBundle\Event\MessageEvent;
use Uecode\Bundle\QPushBundle\Message\Message;

public function onMessageReceived(MessageEvent $event)
{
    $id         = $event->getMessage()->getId();
    $body       = $event->getMessage()->getBody();
    $metadata   = $event->getMessage()->getMetadata();

    // do some processing
}
```

### Cleaning up the Queue

[](#cleaning-up-the-queue)

Once all other Event Listeners have been invoked on a `MessageEvent`, the Bundle will automatically attempt to remove the Message from your Queue for you.

###  Health Score

48

—

FairBetter than 95% of packages

Maintenance19

Infrequent updates — may be unmaintained

Popularity59

Moderate usage in the ecosystem

Community32

Small or concentrated contributor base

Maturity70

Established project with proven stability

 Bus Factor2

2 contributors hold 50%+ of commits

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 ~48 days

Recently: every ~183 days

Total

35

Last Release

2835d ago

Major Versions

0.4.0 → 1.0.02014-02-14

1.4.0 → 2.0.02014-12-17

1.4.1 → 2.0.12015-01-26

2.3.0 → 3.0.02018-03-28

PHP version history (2 changes)0.1.0PHP &gt;=5.4.0

3.0.0PHP &gt;=5.6.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/84ad9179e2241e556ef5d5155b3ec773d40562d325d4f9106c01af365a080a8d?d=identicon)[kmfk](/maintainers/kmfk)

---

Top Contributors

[![k-k](https://avatars.githubusercontent.com/u/2430033?v=4)](https://github.com/k-k "k-k (65 commits)")[![stevenjbrookes](https://avatars.githubusercontent.com/u/1766857?v=4)](https://github.com/stevenjbrookes "stevenjbrookes (23 commits)")[![cordoval](https://avatars.githubusercontent.com/u/328359?v=4)](https://github.com/cordoval "cordoval (11 commits)")[![francoispluchino](https://avatars.githubusercontent.com/u/567393?v=4)](https://github.com/francoispluchino "francoispluchino (10 commits)")[![Gnilya](https://avatars.githubusercontent.com/u/2853725?v=4)](https://github.com/Gnilya "Gnilya (9 commits)")[![cryptiklemur](https://avatars.githubusercontent.com/u/896295?v=4)](https://github.com/cryptiklemur "cryptiklemur (8 commits)")[![jeskew](https://avatars.githubusercontent.com/u/705500?v=4)](https://github.com/jeskew "jeskew (7 commits)")[![czenker](https://avatars.githubusercontent.com/u/264799?v=4)](https://github.com/czenker "czenker (6 commits)")[![eymengunay](https://avatars.githubusercontent.com/u/242627?v=4)](https://github.com/eymengunay "eymengunay (6 commits)")[![danmurf](https://avatars.githubusercontent.com/u/639396?v=4)](https://github.com/danmurf "danmurf (3 commits)")[![xabbuh](https://avatars.githubusercontent.com/u/1957048?v=4)](https://github.com/xabbuh "xabbuh (3 commits)")[![petemcfarlane](https://avatars.githubusercontent.com/u/3472717?v=4)](https://github.com/petemcfarlane "petemcfarlane (3 commits)")[![jakzal](https://avatars.githubusercontent.com/u/190447?v=4)](https://github.com/jakzal "jakzal (2 commits)")[![stof](https://avatars.githubusercontent.com/u/439401?v=4)](https://github.com/stof "stof (2 commits)")[![sprain](https://avatars.githubusercontent.com/u/260361?v=4)](https://github.com/sprain "sprain (2 commits)")[![jamesmoey](https://avatars.githubusercontent.com/u/457472?v=4)](https://github.com/jamesmoey "jamesmoey (2 commits)")[![jmdalmeida](https://avatars.githubusercontent.com/u/1855079?v=4)](https://github.com/jmdalmeida "jmdalmeida (1 commits)")[![glaubinix](https://avatars.githubusercontent.com/u/442056?v=4)](https://github.com/glaubinix "glaubinix (1 commits)")[![bitdeli-chef](https://avatars.githubusercontent.com/u/3092978?v=4)](https://github.com/bitdeli-chef "bitdeli-chef (1 commits)")[![nfabre](https://avatars.githubusercontent.com/u/153861?v=4)](https://github.com/nfabre "nfabre (1 commits)")

---

Tags

symfonybundleawspushqpushpub-subasynchiron mq

### Embed Badge

![Health badge](/badges/uecode-qpush-bundle/health.svg)

```
[![Health](https://phpackages.com/badges/uecode-qpush-bundle/health.svg)](https://phpackages.com/packages/uecode-qpush-bundle)
```

###  Alternatives

[sylius/sylius

E-Commerce platform for PHP, based on Symfony framework.

8.4k5.6M651](/packages/sylius-sylius)[ec-cube/ec-cube

EC-CUBE EC open platform.

78527.0k1](/packages/ec-cube-ec-cube)[cmsig/seal-symfony-bundle

An integration of CMS-IG SEAL search abstraction into Symfony Framework.

15195.8k5](/packages/cmsig-seal-symfony-bundle)[webfactory/icu-translation-bundle

Enables ICU message formatting for translations in Symfony applications.

2761.8k](/packages/webfactory-icu-translation-bundle)

PHPackages © 2026

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