Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Disque
Search
Mariano Iglesias
May 30, 2015
Programming
0
99
Disque
Lightning talk given at New York for CakeFest 2015
Mariano Iglesias
May 30, 2015
Tweet
Share
More Decks by Mariano Iglesias
See All by Mariano Iglesias
Simple is Good, Complex is Bad
mariano
2
150
A future without frameworks
mariano
2
200
Procesando pagos: LO ESTÁS HACIENDO MAL
mariano
0
200
Go aka Golang
mariano
1
110
ElasticSearch: hacer un Google es una papa
mariano
0
73
Random tips that will save your project's life
mariano
0
52
node-db: La excusa perfecta para hablar de C++ y Node.js
mariano
0
77
Episodio VI - El retorno del freelancer
mariano
0
36
Going crazy with NodeJS and CakePHP
mariano
1
70
Other Decks in Programming
See All in Programming
LLMで複雑な検索条件アセットから脱却する!! 生成的検索インタフェースの設計論
po3rin
4
1.1k
組み合わせ爆発にのまれない - 責務分割 x テスト
halhorn
1
190
ZJIT: The Ruby 4 JIT Compiler / Ruby Release 30th Anniversary Party
k0kubun
1
330
メルカリのリーダビリティチームが取り組む、AI時代のスケーラブルな品質文化
cloverrose
2
470
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
720
クラウドに依存しないS3を使った開発術
simesaba80
0
220
Honoを使ったリモートMCPサーバでAIツールとの連携を加速させる!
tosuri13
1
120
副作用をどこに置くか問題:オブジェクト指向で整理する設計判断ツリー
koxya
1
400
20251212 AI 時代的 Legacy Code 營救術 2025 WebConf
mouson
0
250
Spinner 軸ズレ現象を調べたらレンダリング深淵に飲まれた #レバテックMeetup
bengo4com
1
220
CSC307 Lecture 03
javiergs
PRO
1
470
Patterns of Patterns
denyspoltorak
0
450
Featured
See All Featured
Learning to Love Humans: Emotional Interface Design
aarron
274
41k
The SEO Collaboration Effect
kristinabergwall1
0
330
Prompt Engineering for Job Search
mfonobong
0
140
Tips & Tricks on How to Get Your First Job In Tech
honzajavorek
0
410
Agile that works and the tools we love
rasmusluckow
331
21k
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
25
1.7k
Producing Creativity
orderedlist
PRO
348
40k
Heart Work Chapter 1 - Part 1
lfama
PRO
4
35k
Measuring Dark Social's Impact On Conversion and Attribution
stephenakadiri
1
100
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
35
2.3k
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
359
30k
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
231
22k
Transcript
Disque A job queue to win it all
#DoingItWrong
Using Redis as a queue? No longer needed
• Non-blocking server • Distributed • Replication • In memory
• Job acknolwedging • If not acknolwedged, goes back to
queue • Job retries • Job delay
#Run
$ disque /etc/disque/7711.conf $ disque /etc/disque/7712.conf $ disque -p 7711
127.0.0.1:7711> cluster meet 127.0.0.1 7712 OK 127.0.0.1:7711> HELLO 1) (integer) 1 2) "26a390eb07bba018a9ed0591b2110479f16bb19d" 3) 1) "26a390eb07bba018a9ed0591b2110479f16bb19d" 2) "127.0.0.1" 3) "7711" 4) "1" 4) 1) "9ccaa86ceaf032eeb67097d639b80315090f79d5" 2) "127.0.0.1" 3) "7712" 4) "1"
#PHP
github.com/mariano/disque-php $ composer install mariano/disque-php
$disque = new \Disque\Client([ '127.0.0.1:7111', '127.0.0.2:7112' ]); $job = new
\App\Jobs\EmailJob([ 'email' => '
[email protected]
', 'template' => 'signed_up' ]); $disque->queue('emails')->push($job); $job = new \App\Jobs\RemindActivation($user); $disque->queue('emails')->schedule($job, new \DateTime('+1 week'));
$queue = $disque->queue('emails'); while ($job = $queue->pull()) { $job->execute(); $queue->processed($job);
}
#CLIGotchas
• Memory! • Error recovery • SIGINT • supervisord