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
Vert.x Montreal JUG 2018
Search
Julien Ponge
October 25, 2018
Programming
550
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Vert.x Montreal JUG 2018
Julien Ponge
October 25, 2018
More Decks by Julien Ponge
See All by Julien Ponge
Quarkus Insights 2023-03-06
jponge
0
130
Reactive Streams. 4 Interfaces. Et après ?
jponge
0
64
Scalability and resilience in practice: current trends and opportunities
jponge
0
310
Eclipse Vert.x at BruJUG 2019
jponge
0
210
Du réactif au service du pneu connecté
jponge
0
390
Bringing Reactive to Enterprise Java Developers
jponge
0
350
Golo LyonJUG 2019
jponge
0
300
Bringing Reactive to Enterprise Application Developer // Reactive Summit 2018
jponge
0
300
Démystifier le réactif et l'orchestration de services avec Vert.x, Kubernetes et Kotlin
jponge
0
290
Other Decks in Programming
See All in Programming
TSKaigi Night Talks 2026_TypeScriptでサプライチェーンの整合性を型に閉じ込める
geekplus_tech
0
310
関係性から理解する"同一性"の型用語たち
pvcresin
2
640
GitHub Copilot CLIのいいところ
htkym
2
1.3k
AIとRubyの静的型付け
ukin0k0
0
540
Webフレームワークの ベンチマークについて
yusukebe
0
140
Lessons from Spec-Driven Development
simas
PRO
0
140
These Five Tricks Can Make Your Apps Greener, Cheaper, & Nicer
hollycummins
0
280
Old Dog, New Tricks: The Java 25 Reinvention - JNation
bazlur_rahman
0
150
CSC307 Lecture 17
javiergs
PRO
0
320
Make SRE Operations Easier with Azure SRE Agent
kkamegawa
0
4.3k
エージェンティックRAGにAWSで入門しよう!
har1101
8
1.2k
Composerを使ったサプライチェーン攻撃の様子を眺めてみる #phpstudy
o0h
PRO
2
220
Featured
See All Featured
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
12
1.2k
The Curse of the Amulet
leimatthew05
1
13k
ReactJS: Keep Simple. Everything can be a component!
pedronauck
666
130k
CoffeeScript is Beautiful & I Never Want to Write Plain JavaScript Again
sstephenson
162
16k
Effective software design: The role of men in debugging patriarchy in IT @ Voxxed Days AMS
baasie
0
390
GitHub's CSS Performance
jonrohan
1033
470k
Evolving SEO for Evolving Search Engines
ryanjones
0
210
A Soul's Torment
seathinner
6
2.9k
Discover your Explorer Soul
emna__ayadi
2
1.1k
Connecting the Dots Between Site Speed, User Experience & Your Business [WebExpo 2025]
tammyeverts
11
940
Making Projects Easy
brettharned
120
6.7k
Navigating Algorithm Shifts & AI Overviews - #SMXNext
aleyda
1
1.3k
Transcript
Julien Ponge Thomas Segismont @jponge @tsegismont
Shameless plug
Reactive? (because resources are scarce)
None
Application
Reactive systems Reactive streams Reactive programming Reactive “Responding to stimuli”
Manifesto, Actor, Messages Resilience, Elasticity, Scalability, Asynchronous, non-blocking Data flow Back-pressure Non-blocking Data flow Events, Observable Spreadsheets Akka, Vert.x Akka Streams, RxJava, Reactor, Vert.x Reactor, Reactive Spring, RxJava, Vert.x
while (isRunning) { String line = bufferedReader.readLine(); switch (line.substring(0, 4))
{ case "ECHO": bufferedWriter.write(line); break // ... // other cases ( ...) // ... default: bufferedWriter.write("UNKW Unknown command"); } }
x 1000 = !
Virtual machines, Containers, etc
None
Vert.x? (async all the things!)
Eclipse Vert.x Open source project started in 2012 Eclipse /
Apache licensing A toolkit for building reactive applications for the JVM 7K ⋆ on # Built on top of $ https://vertx.io % @vertx_project
& ' & Http server verticle Database client verticle
Event Bus ) ' “Details for user 1234?” “{data}” 4 instances 1 instance
Events Thread Event Loop & & & & &
(demo) Hello Vert.x
None
foo.a(1, res1 -> { if (res1.succeeded()) { bar.b("abc", 1, res2
-> { if (res.succeeded()) { baz.c(res3 -> { dosomething(res1, res2, res3, res4 -> { // (...) }); }); } }); } }); “Callback hell”
Callbacks RxJava 1 + 2 Quasar (vertx-sync) Kotlin coroutines (core)
(codegen)
Boiler Vroom (in the mix)
(demo)
* ) WebMidi JSON / Event Bus
const eventBus = new EventBus("/eventbus") traktorIn.addListener("controlchange", 5, (event) => {
eventBus.publish("boilervroom.vu-meter", { type: "volume-level", value: event.value }) }) eventBus.publish("boilervroom.fromtraktor", { type: "filter", number: 1, value: (event.value !== 0) }) Event Bus
+ , - . IceCast VLC * Chrome / DJ
Booth app Clients / NuProcess MIDI Event Bus Event Bus
SockJSHandler sockJSHandler = SockJSHandler.create(vertx); PermittedOptions permittedOptions = new PermittedOptions() .setAddressRegex(“boilervroom\\
..+”); BridgeOptions bridgeOptions = new BridgeOptions() .addInboundPermitted(permittedOptions) .addOutboundPermitted(permittedOptions); sockJSHandler.bridge(bridgeOptions); router.route("/eventbus /*").handler(sockJSHandler);
+ , - . IceCast VLC Clients / OGG/Vorbis OGG/Vorbis
MP3 MP3 HTTP 1.0 HTTP 1.1 HTTP Client Event bus → Chunked HTTP
router.get("/audiostream").handler(context -> { HttpServerResponse response = context.response(); response.setStatusCode(200); response.setChunked(true); response.putHeader("Content-Type",
"audio/mpeg"); MessageConsumer<Buffer> consumer = eventBus.consumer("boilervroom.audiostream"); consumer.bodyStream().handler(buffer -> { if (!response.writeQueueFull()) { response.write(buffer); } }); response.endHandler(v -> { consumer.unregister(); }); response.exceptionHandler(t -> { consumer.unregister(); }); });
Outro
Unified end-to-end reactive model + ecosystem (not just APIs…) For
all kinds of distributed applications (even the small-scale ones) Flexible toolkit, not a framework (your needs, your call)
https: //youtu.be/ZkWsilpiSqw 0 Applications réactives avec Eclipse Vert.x 1 Building
Reactive Microservices in Java https: //goo.gl/ep6yB9 1 Guide to async programming with Vert.x for Java developers https: //goo.gl/AcWW3A
Q&A Use mlponge to get 50% off