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
Polyglot
Search
Sau Sheong Chang
October 10, 2014
Technology
0
83
Polyglot
How To Write A Web App in 6 Programming Languages
Sau Sheong Chang
October 10, 2014
Tweet
Share
More Decks by Sau Sheong Chang
See All by Sau Sheong Chang
Genetic Algorithms with Go
sausheong
0
150
Programming Complexity
sausheong
0
940
Rollicking Ruby Robots Rule the World
sausheong
0
250
3 Things You May Not Know About The Go Template Engine
sausheong
0
340
Money, Sex and Evolution (v3)
sausheong
0
97
Developing Web Applications with Go
sausheong
7
800
Money, Sex and Evolution
sausheong
1
100
A Tale of Two Frameworks
sausheong
0
73
Ruby, Rock and Roll
sausheong
3
300
Other Decks in Technology
See All in Technology
Azure Well-Architected Framework入門
tomokusaba
1
290
それでも私はContextに値を詰めたい | Go Conference 2025 / go conference 2025 fill context
budougumi0617
4
1.2k
データエンジニアがこの先生きのこるには...?
10xinc
0
440
Escaping_the_Kraken_-_October_2025.pdf
mdalmijn
0
130
ZOZOのAI活用実践〜社内基盤からサービス応用まで〜
zozotech
PRO
0
170
AWSにおけるTrend Vision Oneの効果について
shimak
0
120
生成AIを活用したZennの取り組み事例
ryosukeigarashi
0
200
自作LLM Native GORM Pluginで実現する AI Agentバックテスト基盤構築
po3rin
2
250
OpenAI gpt-oss ファインチューニング入門
kmotohas
2
960
ユニットテストに対する考え方の変遷 / Everyone should watch his live coding
mdstoy
0
130
pprof vs runtime/trace (FlightRecorder)
task4233
0
160
Findy Team+のSOC2取得までの道のり
rvirus0817
0
330
Featured
See All Featured
Unsuck your backbone
ammeep
671
58k
How GitHub (no longer) Works
holman
315
140k
4 Signs Your Business is Dying
shpigford
185
22k
Writing Fast Ruby
sferik
629
62k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
29
2.6k
GraphQLの誤解/rethinking-graphql
sonatard
73
11k
Docker and Python
trallard
46
3.6k
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
4k
Optimizing for Happiness
mojombo
379
70k
A Modern Web Designer's Workflow
chriscoyier
697
190k
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
52
5.6k
Building Applications with DynamoDB
mza
96
6.6k
Transcript
Polyglot Or How To Write A Web App in 6
Programming Languages Chang Sau Sheong Oct 2014 1
* http://spectrum.ieee.org/computing/software/top-‐10-‐programming-‐languages 2
*http://blog.codeeval.com/codeevalblog/2014 3
Programming language wars 4
Dependency hell 5
Polyglot 6
Build your web app with any language 7
All at once 8
Acceptor HTTP Responder Responder Responder POST/_/post Responder Responder Responder GET/_/posts
Acceptor HTTP Acceptor HTTP Broker ZMQ ZMQ Responder Responder Responder GET/_/post/new 9
10 Acceptor P
11 P Broker
12 Responder You need to write this
Simple responder require 'securerandom' require 'bundler' Bundler.require broker = "tcp://localhost:4321"
routeid = "GET/_/hello/ruby" identity = SecureRandom.uuid puts "#{routeid} - #{identity} responder ready." ctx = ZMQ::Context.new client = ctx.socket ZMQ::REQ client.identity = identity client.connect broker client.send_string routeid loop do request = String.new client.recv_string request response = [routeid, "200", "{\"Content-Type\": \"text/html\"}", "Hello World"] client.send_strings response end Define route ID and unique responder identity Connect to broker Register responder Receive request and process it Return with response 13
Distributed by default 14
15 Broker Acceptor Responder Responder Responder
Scale as you like it 16
17 Broker Acceptor Responder Responder Responder Acceptor Responder
Evolve your web app 18
19 Broker Acceptor Responder Responder Responder
Still Evolving (need your feedback and help) 20
http://github.com/sausheong/polyglot
[email protected]
@sausheong 21