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
Swarrot, a library to consume them all!
Search
Olivier Dolbeau
October 20, 2015
Programming
0
390
Swarrot, a library to consume them all!
Talk given at BlaBlaCar Tech Meetup in Warsaw
Olivier Dolbeau
October 20, 2015
Tweet
Share
More Decks by Olivier Dolbeau
See All by Olivier Dolbeau
Jane & Webby
odolbeau
0
300
Translating a monolingual application
odolbeau
2
430
DX: Developer eXperience
odolbeau
0
54
DX: Developer eXperience
odolbeau
0
420
EasyAdminBundle introduction
odolbeau
0
140
REX API Platform
odolbeau
0
1.1k
Features flags at BlaBlaCar
odolbeau
4
880
25+ million members in 22 countries, how to scale with Symfony2
odolbeau
1
390
Be gentle with your prod!
odolbeau
1
630
Other Decks in Programming
See All in Programming
日付と正規化
megmogmog1965
0
140
CSC307 Lecture 11
javiergs
PRO
0
240
How to use Macrobenchmark
veronikapj
0
160
From Spring Boot 2 to Spring Boot 3 with Java 22 and Jakarta EE
ivargrimstad
0
1.9k
[After Kotlin Fest 2024 LT Night @ Sansan] もっともっとKotlinを好きになる!K2 Compiler Pluginで遊んでみよう!
kitakkun
2
260
社内 LT 会を発足し、アウトプット文化を醸成させるために考えたこと・やったこと / Starting internal LT meetings and fostering an output culture
mackey0225
3
120
Jetpack for KMP
fornewid
1
290
【Go言語】golangci-lintの使い方
tomo1227
0
270
HMSコンペ 11th Solution (team : kansai-kaggler)
t88
1
680
CSC307 Lecture 10
javiergs
PRO
0
310
最近追加した型の紹介とその振り返り
aki19035vc
0
170
CSC307 Lecture 05
javiergs
PRO
0
210
Featured
See All Featured
Build your cross-platform service in a week with App Engine
jlugia
227
17k
Design by the Numbers
sachag
277
18k
Teambox: Starting and Learning
jrom
130
8.6k
CoffeeScript is Beautiful & I Never Want to Write Plain JavaScript Again
sstephenson
155
14k
10 Git Anti Patterns You Should be Aware of
lemiorhan
652
58k
Designing for Performance
lara
604
67k
Rebuilding a faster, lazier Slack
samanthasiow
78
8.5k
Web Components: a chance to create the future
zenorocha
307
41k
It's Worth the Effort
3n
181
27k
Gamification - CAS2011
davidbonilla
78
4.9k
Testing 201, or: Great Expectations
jmmastey
33
6.9k
Faster Mobile Websites
deanohume
303
30k
Transcript
None
@odolbeau Web Architect Olivier Dolbeau
None
What happens when you publish a trip?
We send an email to the driver. We index the
trip in ElasticSearch. We send the comment to moderation spooler. We store all relevant informations in Hadoop for BI.
I’m gonna sleep, tell me when you’re done!
None
None
“RabbitMQ is a message broker. The principal idea is pretty
simple: it accepts and forwards messages.”
Publisher Queue1 Exchange Queue2 Queue3 Consumer Consumer Consumer Consumer RabbitMQ
What happens when you publish a trip?
We send an email to the driver. We index the
trip in ElasticSearch. We sent the comment in moderation. We store all relevant informations in Hadoop for BI.
RabbitMQ Application mail publication indexation bi Consumer mail Consumer bi
Consumer indexation Consumer moderation moderation
So cool!
That’s fast! At least for the user.
We have several small applications.
We can scale!
Problems...
Long running processes.
Expect errors. Deal with them. • Catch them! • Retry
when needed. • Don’t stop your consumer.
Your worker need to be stopped correctly.
None
Goals
Solve mentioned problems.
Be able to change the broker used.
Implementation
We need a MessageProvider. We use the pecl extension.
Here is our “business” logic.
Let’s consume them all!
Encapsulation FTW! <3
Let’s create a stack.
The result.
None
Used in production.
None
Sometimes, dealing with consumers can be a pain...
Use a message broker, that’s awesome!
Sometimes, dealing with consumers can be a pain, BUT you
should definitively use a Message Broker! <3 Olivier Dolbeau @odolbeau