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
400
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
Throw new \Exception(); Oui, mais laquelle ?
odolbeau
0
82
Jane & Webby
odolbeau
0
310
Translating a monolingual application
odolbeau
2
460
DX: Developer eXperience
odolbeau
0
56
DX: Developer eXperience
odolbeau
0
450
EasyAdminBundle introduction
odolbeau
0
150
REX API Platform
odolbeau
0
1.2k
Features flags at BlaBlaCar
odolbeau
4
940
25+ million members in 22 countries, how to scale with Symfony2
odolbeau
1
430
Other Decks in Programming
See All in Programming
Amazon Qを使ってIaCを触ろう!
maruto
0
420
Click-free releases & the making of a CLI app
oheyadam
2
120
A Journey of Contribution and Collaboration in Open Source
ivargrimstad
0
1k
What’s New in Compose Multiplatform - A Live Tour (droidcon London 2024)
zsmb
1
480
watsonx.ai Dojo #4 生成AIを使ったアプリ開発、応用編
oniak3ibm
PRO
1
150
.NET のための通信フレームワーク MagicOnion 入門 / Introduction to MagicOnion
mayuki
1
1.7k
Nurturing OpenJDK distribution: Eclipse Temurin Success History and plan
ivargrimstad
0
990
ペアーズにおけるAmazon Bedrockを⽤いた障害対応⽀援 ⽣成AIツールの導⼊事例 @ 20241115配信AWSウェビナー登壇
fukubaka0825
6
2k
ActiveSupport::Notifications supporting instrumentation of Rails apps with OpenTelemetry
ymtdzzz
1
250
Realtime API 入門
riofujimon
0
150
RubyLSPのマルチバイト文字対応
notfounds
0
120
型付き API リクエストを実現するいくつかの手法とその選択 / Typed API Request
euxn23
8
2.2k
Featured
See All Featured
Visualization
eitanlees
145
15k
Designing on Purpose - Digital PM Summit 2013
jponch
115
7k
BBQ
matthewcrist
85
9.3k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
42
9.2k
Build your cross-platform service in a week with App Engine
jlugia
229
18k
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
31
2.7k
Testing 201, or: Great Expectations
jmmastey
38
7.1k
VelocityConf: Rendering Performance Case Studies
addyosmani
325
24k
A Tale of Four Properties
chriscoyier
156
23k
Helping Users Find Their Own Way: Creating Modern Search Experiences
danielanewman
29
2.3k
Cheating the UX When There Is Nothing More to Optimize - PixelPioneers
stephaniewalter
280
13k
How STYLIGHT went responsive
nonsquared
95
5.2k
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