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
Spacer - iThome Serverless All-Star
Search
Poga Po
March 29, 2018
Technology
2
280
Spacer - iThome Serverless All-Star
Poga Po
March 29, 2018
Tweet
Share
More Decks by Poga Po
See All by Poga Po
civic-notebook
poga
0
100
Fuzz Testing and go-fuzz
poga
0
350
everything is log
poga
12
1.8k
g0v intro
poga
0
90
新聞產生器
poga
0
640
RESTful API @ Front-End Developers Taiwan 2014-04-23
poga
3
160
Dependency Management in Go
poga
4
630
Redis: based on real story
poga
16
1.3k
Other Decks in Technology
See All in Technology
Azureコストと向き合った、4年半のリアル / Four and a half years of dealing with Azure costs
aeonpeople
1
250
「魔法少女まどか☆マギカ Magia Exedra」の多様なバトルの開発を柔軟かつ効率的に実現するためのPure C#とUnityの分離について
gree_tech
PRO
0
230
あなたの知らない Linuxカーネル脆弱性の世界
recruitengineers
PRO
3
130
旅で応援する✈️ NEWTが目指すコミュニティ支援とあたらしい旅行 / New Travel: Supporting by NEWT on Your Journey
mii3king
0
120
Click A, Buy B: Rethinking Conversion Attribution in ECommerce Recommendations
lycorptech_jp
PRO
0
120
HR Force における DWH の併用事例 ~ サービス基盤としての BigQuery / 分析基盤としての Snowflake ~@Cross Data Platforms Meetup #2「BigQueryと愉快な仲間たち」
ryo_suzuki
0
250
「改善」ってこれでいいんだっけ?
ukigmo_hiro
0
390
サイバーエージェント流クラウドコスト削減施策「みんなで金塊堀太郎」
kurochan
4
2.2k
dbtとBigQuery MLで実現する リクルートの営業支援基盤のモデル開発と保守運用
recruitengineers
PRO
3
150
エンタメとAIのための3Dパラレルワールド構築(GPU UNITE 2025 特別講演)
pfn
PRO
0
620
LLMプロダクトの信頼性を上げるには?LLM Observabilityによる、対話型音声AIアプリケーションの安定運用
ivry_presentationmaterials
0
740
OAuthからOIDCへ ― 認可の仕組みが認証に拡張されるまで
yamatai1212
0
150
Featured
See All Featured
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
PRO
23
1.5k
How GitHub (no longer) Works
holman
315
140k
Optimising Largest Contentful Paint
csswizardry
37
3.5k
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
230
22k
Keith and Marios Guide to Fast Websites
keithpitt
411
23k
Embracing the Ebb and Flow
colly
88
4.9k
Building Better People: How to give real-time feedback that sticks.
wjessup
369
20k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
36
6.1k
Art, The Web, and Tiny UX
lynnandtonic
303
21k
The Illustrated Children's Guide to Kubernetes
chrisshort
49
51k
How to Ace a Technical Interview
jacobian
280
24k
The Straight Up "How To Draw Better" Workshop
denniskardys
238
140k
Transcript
Poga. 2018.03.29
Serverless • 以 function 為執行單位 • 按照每個 function 使用的資 源量計費
Hello World (Lua) function (args) return "Hello from Spacer!" end
Code
Calling Other Functions -- by name local flow = require
"flow" flow.call("foo") Code
Calling Other Functions -- by require local foo = require
"foo" foo() Code
Expose Function as Public JSON API with Lua local Gateway
= { -- HTTP Method, Path, Function {"GET", "/hello", "hello"} } Code
Spacer • 流暢的開發體驗:Optimized for programmer happiness • 極低的架設門檻:不依賴 kubernetes、container、VM ◦
Minimal Dependency: nginx & PostgreSQL • Why? Nginx & Lua Code
Serverless is Hard Architecture
“Just a function” - Container • Programming languages • Sandbox
• Performance ◦ Inter-function communication、RPC ◦ Cold Start Architecture
“Just a function” - Scheduling • Manage container images •
Load/Unload containers • Event-Trigger • Kubernetes? Architecture
How Spacer Work • Lua • Nginx (openresty) • Kappa
Architecture Architecture
• Since 1993 • Embeddable Script Language • Lightweight Sandboxed
Lua VM • High-performance (LuaJIT): ◦ Game Engine ◦ CDN ◦ CERN ◦ Super Computers Architecture
• Common Gateway Interface (1993) • Openresty ◦ (nginx +
LuaJIT) ◦ Schedule Lua VM with nginx workers Architecture
Kappa Architecture “Where everything is a stream” • A software
architecture pattern • Append-only immutable event log • Real-time, Streaming Architecture
Spacer: Simple, Solid, Proven Technologies Serverless frameworks Spacer Sandbox/Package Container
Lua Scheduling Kubernetes nginx(openresty) Event ? Kappa architecture Architecture
Spacer is Platform Agnostic Architecture
But Why Serverless? philosophy
「好程式」 • 容易擴充、容易維護的架構 • 永遠是第一個被犧牲 • 「我們另外安排時間重構」- 主管,永遠不會實現 • 開發越來越慢、開發者心情越來越差、產品更新速度大減
◦ 最後失敗 philosophy
「好程式」 • 軟體架構的價值太難量化 • 對非專業人士來說太難理解 philosophy
「好程式」in serverless • 軟體架構 = 營運成本 • 重構 = Cost
Down • 開發者得到更多優化的空間 philosophy
看不懂軟體架構,也看的懂帳單的金額 philosophy
「好產品」 • 軟體開發: ◦ 定 Spec、定時程 ◦ 難以專注在用戶需求上 • 「從一條
SQL 到上線的距離有多遠?」 philosophy
「好產品」in Serverless • 不用分心在架構與技術細節上 ◦ 產品上線速度更快 • 更精細的產品分析: ◦ 一個
User 進來後,平均搜尋了幾次,花了多少成本? ◦ 一個 User 平均帶來的收入是? ◦ 優化: ▪ 流量? ▪ Function 效能? ▪ 轉換率? philosophy
「開發費用」 • 報價 10 萬跟 100 萬的差別在哪? • 維護費? •
Serverless ◦ 成本透明,按照用量收費 ◦ 開發者與客戶目標一致:提高產品價值 philosophy
Spacer: Simplified Serverless philosophy
Serverless: From Engineering to Utility philosophy
Thanks! github.com/poga/spacer