Queue tagging
- 主要言語
- C
- スター
- 8.1k
- フォーク
- 532
- PR マージ指標
- 30日以内にマージされた PR はありません
説明
Hey guys
I'm looking to move from SoftLayers message queue to Disque in the future once a stable release is out.
However one of the features that I've found incredibly useful from SL's messaging queue is the ability to tag queues.
For example we have several workflows for when a new user registers (e.g. welcome email, schedule on-boarding drip feed etc). Instead of having to persist somewhere the name of each queue and its role we can simply collect up all the queues with the tag `user_register` and submit the same message to each.
``` php
$queues = $messaging->queues(array('user_register'));
foreach ($queues as $q)
{
$q->message()
->addField('userId', $user->getId())
->create();
}
```
This means if we add a new worker that wants to ingest messages relating to that tag (e.g. a feedback email) we just need to add that tag to the queue and then they will receive those messages.
As I understand this would require making queues somewhat persistent as currently they only exist while they contain messages.
コントリビューションガイド
このリポジトリのコントリビューションガイドは索引されていません
評価
この issue はまだ評価されていません。