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
Websocket en WAMP in sPHPace
Search
Davy De Coster
May 26, 2020
Programming
0
140
Websocket en WAMP in sPHPace
Davy De Coster
May 26, 2020
Tweet
Share
Other Decks in Programming
See All in Programming
The Implementations of Advanced LR Parser Algorithm
junk0612
1
910
七輪ライブラリー: Claude AI で作る Next.js アプリ
suneo3476
1
150
メモリウォールを超えて:キャッシュメモリ技術の進歩
kawayu
0
1.9k
Contribute to Comunities | React Tokyo Meetup #4 LT
sasagar
0
580
Cursorを活用したAIプログラミングについて 入門
rect
0
120
ASP.NETアプリケーションのモダナイゼーションについて
tomokusaba
0
210
「理解」を重視したAI活用開発
fast_doctor
0
220
Unlock the Potential of Swift Code Generation
rockname
0
280
タイムゾーンの奥地は思ったよりも闇深いかもしれない
suguruooki
1
790
GitHub Copilot for Azureを使い倒したい
ymd65536
1
270
ComposeでのPicture in Picture
takathemax
0
130
Ruby on Railroad: The Power of Visualizing CFG
ydah
0
270
Featured
See All Featured
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
3.8k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
507
140k
The Myth of the Modular Monolith - Day 2 Keynote - Rails World 2024
eileencodes
23
2.7k
Stop Working from a Prison Cell
hatefulcrawdad
268
20k
Rebuilding a faster, lazier Slack
samanthasiow
81
9k
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
29
9.4k
Fantastic passwords and where to find them - at NoRuKo
philnash
51
3.2k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
45
9.5k
How STYLIGHT went responsive
nonsquared
100
5.5k
4 Signs Your Business is Dying
shpigford
183
22k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
52
2.4k
Making Projects Easy
brettharned
116
6.1k
Transcript
Websocket en WAMP in sPHPace
About
Davy De Coster Backend Developer @ Ocular Twitter: @davydecoster
None
None
Websocket?
Websocket Protocol • Bestaat sinds 2010 – RFC sinds december
2011 (https://tools.ietf.org/html/rfc6455) • Realtime communicatiekanaal • Lage overhead tov polling • ws:// en wss:// • Meerdere subprotocollen • Veel gebruikt: socket.io
Websocket in PHP • Ratchet Package (http://socketo.me/) • Websocket server
in PHP
DEMO
Subprotocollen • Meerdere implementaties (https://www.iana.org/assignments/websocket/websocket.xml)
WAMP?
WAMP • Web Application Messaging Protocol • Crossbar.io • Publish
& Subscribe naar topics (PubSub) • Remote Procedure Call (RPC) • Veel gebruikt bij IoT
Crossbar.io - Connection & security • Python • Realms •
Namespace • Roles • Security • Authentication • Veel platformen kunnen hiermee connecteren • Build in Docker container • Data in args en kwargs
PubSub • Topic = ‘be.ocular.demo’ • Subscribe om events te
ontvangen • Publish om event te sturen
RPC • Registreer procedure op topic (‘be.ocular.doe.iets’) • Procedure is
uniek • Call een topic om de procedure uit te voeren • Procedure kan iets returnen naar caller
WAMP - Schema
WAMP in PHP • Voryx/Thruway (https://github.com/voryx/Thruway) • Non-blocking
DEMO
Real-life voorbeelden
None
None
None
Questions?
Merci!