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
OpenIL vol.1
Search
Take
February 21, 2014
Technology
0
3.6k
OpenIL vol.1
http://www.infiniteloop.co.jp/blog/2014/02/publicstudy01/
Take
February 21, 2014
Tweet
Share
More Decks by Take
See All by Take
トルテが実践したマッチしたユーザーを除く3つの方法/torte-es
ww24
1
12k
トルテリリースまでの Go Tips 16/torte-go-tips-16
ww24
1
11k
AMEBA OWND DE HTTP/2
ww24
0
450
Service Workers Push API Hands-on
ww24
1
160
Other Decks in Technology
See All in Technology
Introduction to Works of ML Engineer in LY Corporation
lycorp_recruit_jp
0
120
The Rise of LLMOps
asei
7
1.4k
強いチームと開発生産性
onk
PRO
34
11k
ノーコードデータ分析ツールで体験する時系列データ分析超入門
negi111111
0
410
[FOSS4G 2024 Japan LT] LLMを使ってGISデータ解析を自動化したい!
nssv
1
210
Making your applications cross-environment - OSCG 2024 NA
salaboy
0
190
ISUCONに強くなるかもしれない日々の過ごしかた/Findy ISUCON 2024-11-14
fujiwara3
8
870
OCI 運用監視サービス 概要
oracle4engineer
PRO
0
4.8k
なぜ今 AI Agent なのか _近藤憲児
kenjikondobai
4
1.4k
これまでの計測・開発・デプロイ方法全部見せます! / Findy ISUCON 2024-11-14
tohutohu
3
370
OCI Network Firewall 概要
oracle4engineer
PRO
0
4.1k
AGIについてChatGPTに聞いてみた
blueb
0
130
Featured
See All Featured
XXLCSS - How to scale CSS and keep your sanity
sugarenia
246
1.3M
Become a Pro
speakerdeck
PRO
25
5k
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
47
5k
Writing Fast Ruby
sferik
627
61k
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
31
2.7k
Intergalactic Javascript Robots from Outer Space
tanoku
269
27k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
44
6.8k
GraphQLとの向き合い方2022年版
quramy
43
13k
Statistics for Hackers
jakevdp
796
220k
Code Reviewing Like a Champion
maltzj
520
39k
Embracing the Ebb and Flow
colly
84
4.5k
Optimising Largest Contentful Paint
csswizardry
33
2.9k
Transcript
SMARTPHONE CONTROLLER OpenIL vol.1 த ݑ
ࣗݾհ • var age = 19 ࡀ (ੜ 2/24) •
ւಓۀେֶɹֶ෦ 2 ੜ • ΠϯϑΟχοτϧʔϓɹΞϧόΠτ • झຯཱྀߦɺࣸਅɺϓϩάϥϛϯά • Web Developer
͋ͱ 3 Ͱ age++ ͢ΔΠϕϯτ͕ɻ
p.tl/53x8 24 ࣌ؒडத
WORKS • IT ษڧձΧϨϯμʔ for Android & iOS • Image
Shortener - [img.ww24.jp] • Realtime Chat - [rtc.ww24.jp] • Connect Smartphone - [connect-sp.ww24.jp]
IT ษڧձΧϨϯμʔ εϚʔτϑΥϯΞϓϦ
IMAGE SHORTENER ॖ URL Λར༻ͨ͠ΦϯϥΠϯετϨʔδ
REALTIME CHAT Google Drive Realtime API Λར༻ͨ͠ Chat
CONNECT SMARTPHONE ύιίϯͱεϚϗͷϦΞϧλΠϜ࿈ܞ
CONNECT SMARTPHONE
CONNECT SMARTPHONE • Express.IO ΛͬͨɺεϚʔτϑΥϯͱύι ίϯͷϦΞϧλΠϜͳ࿈ܞΞϓϦέʔγϣϯ
AGENDA • ϦΞϧλΠϜͳ࿈ܞͱ • Express ͱ Socket.IO • Έ •
σϞ • αϯϓϧίʔυ • ɺ՝
CONNECT SMARTPHONE • ϦΞϧλΠϜͳ࿈ܞͷྫ • Chrome World Wide Maze •
https://chrome.com/maze/ • jsdo.it WebSocket Controller • http://jsdo.it/controller
CHROME WORLD WIDE MAZE Google ͷ໎࿏ήʔϜ
WEBSOCKET CONTROLLER jsdo.it
CONNECT SMARTPHONE εϚʔτϑΥϯΛύιίϯܨ͛ͯɺίϯτϩʔϥʹɻ
CONNECT SMARTPHONE • Έ • WebSocket Server (Socket.IO) • Web
Application Server (Express.js) • Socket.IO + Express.js = Express.IO
ۚͷ EXPRESS ޠௐͰղઆ
EXPRESS ͱ SOCKET.IO ͋ΔϓϩάϥϚ͕ίʔυΛॻ͍͍ͯͨͱ͜Ζɺ git commit ͢Δલʹख͕ͬͯΤσΟλ͝ͱ མͱͯ͠͠·͍·ͨ͠ɻ! ͢Δͱɺಥવঁਆ͕ݱΕʮ͋ͳ͕ͨམͱͨ͠ͷۚͷ express
Ͱ͔͢ʁͦΕͱۜͷ Socket.IO Ͱ͔͢ʁʯͱਘͶ͖ͯ·ͨ͠ɻ
EXPRESS ͱ SOCKET.IO ਖ਼ऀͷϓϩάϥϚɺʮࢲ͕མͱͨ͠ͷੜͷ WebSocket Ͱ௨৴͢ΔεύήοςΟίʔυ Ͱ͢ʯͱ͑·͢ɻ
EXPRESS ͱ SOCKET.IO ਖ਼ऀͷϓϩάϥϚʹײ৺ͨ͠ঁਆɺ! express ͱ Socket.IO Λֻ͚߹Θͤͨɺ express.io ΛϓϩάϥϚʹत͚ΔͷͰͨ͠ɻ
ຊͱແؔͰ͢ɻ
None
EXPRESS.IO express ͷΑ͏ͳײతͳϧʔςΟϯά express ͱڞ༗Ͱ͖Δηογϣϯ
CONNECT SMARTPHONE /connect/{connection_id}ɹʹϦμΠϨΫτ ɹଓɹॲɹཧ ΞϓϦέʔγϣϯɾήʔϜϖʔδʹϦμΠϨΫτ
CONNECT SMARTPHONE Connect Smartphone Smartphone (ࢠ) PC () Game Page
1 2 2 3 3 /connect/KCL98U
CONNECT SMARTPHONE Connect Smartphone Smartphone (ࢠ) PC () Game Page
Socket.IO
CONNECT SMARTPHONE • Connect Smartphone Ͱͷଓॲཧ • ཚ͔Β connection_id ੜ
• ͱࢠΛ connection_id Ͱর߹ • ʹଓ(ࢠ)ͷҰཡΛදࣔ
None
None
None
None
DEMO connect-sp.ww24.jp
αϯϓϧίʔυ
ଓ
ૹ৴ (ࢠ)
ड৴ ()
CONNECT SMARTPHONE • • ಉ͡ϒϥβͰ 2 ը໘։͘ͱɺશ͘ಉ͡ηογϣϯ ใΛ͍࣋ͬͯΔͷͰɺͲͪΒ͕͔ผͰ͖ͳ͍ !
! ઌʹଓ͖ͯͨ͠ํ͕Ͱྑ͍ΑͶʂ ͨ·ʹόάΔ
྆ํࢠͱఆ͞ΕΔ͜ͱ͕͋Δɻ
CONNECT SMARTPHONE • ͳͥͦ͏ͳΔ͔… • HTTP ϦΫΤετεςʔτϨεɻঢ়ଶΛ࣋ͨͳ ͍ɻঢ়ଶΛ࣋ͨͤΔͨΊʹηογϣϯΛ༻͍Δɻ • WebSocket
௨৴εςʔτϑϧɻίωΫγϣϯຖ ʹݸʑʹঢ়ଶΛอ࣋Ͱ͖Δɻϒϥβ͕ಉ͡Ͱ͋ͬ ͯɺ͔ࢠ͔ఆՄೳɻ
CONNECT SMARTPHONE • ϦμΠϨΫτͤ͞Δ࣮ʹͨ͠ཧ༝ • ελϯυΞϩϯͳ࣮Λࢦͨ͠ • αʔόͷ࣮ෆཁͰϦΞϧλΠϜ࿈ܞΛ࣮ݱ • URL
ϧʔςΟϯάࢠͷೝূͳͲɺ໘ ͳॲཧΛҰׅͯ͠ߦͬͨ
ࠓޙͷ՝ • ࣗಈతʹೝূ͍ͨ͠ • ύιίϯ㱻εϚϗʹݶΒͣɺ ήʔϜͰϓϨΠϠʔϚονϯάͰ͖ͦ͏
ϦΞϧλΠϜ௨৴ָ͍͠ʂ
express.io Ͱ շదͳϦΞϧλΠϜ௨৴ϥΠϑΛ