Upgrade to PRO for Only $50/Year—Limited-Time Offer! 🔥
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
PyCon2014China-Zhuhai-high performance
Search
Zoom.Quiet
November 17, 2014
Technology
0
170
PyCon2014China-Zhuhai-high performance
141115 in Zhuhai
http://zoomq.qiniudn.com/CPyUG/PyCon2014China/141115zh-pm6-pyhq.MP3
Zoom.Quiet
November 17, 2014
Tweet
Share
More Decks by Zoom.Quiet
See All by Zoom.Quiet
PyCon2014China-Zhuhai-meta programming
zoomquiet
1
150
PyCon2014China-Zhuhai-bpm.py
zoomquiet
0
120
PyCon2014China-Zhuhai-luna kv db
zoomquiet
0
100
PyCon2014China-Zhuhai-seed studio
zoomquiet
0
110
PyCon2014China-Zhuhai-Docker Registry Build By Python
zoomquiet
0
130
PyCon2014China-Zhuhai-jeff
zoomquiet
0
100
PyCon2014China-Zhuhai-pythonic front-end
zoomquiet
0
130
DevFest2014-Zhuhai-Polymer
zoomquiet
0
430
TEDxJLUZH MOMENT future
zoomquiet
0
390
Other Decks in Technology
See All in Technology
New Relic 1 年生の振り返りと Cloud Cost Intelligence について #NRUG
play_inc
0
240
AI との良い付き合い方を僕らは誰も知らない
asei
0
270
AI時代のワークフロー設計〜Durable Functions / Step Functions / Strands Agents を添えて〜
yakumo
3
2.2k
Amazon Connect アップデート! AIエージェントにMCPツールを設定してみた!
ysuzuki
0
140
202512_AIoT.pdf
iotcomjpadmin
0
150
AR Guitar: Expanding Guitar Performance from a Live House to Urban Space
ekito_station
0
230
子育てで想像してなかった「見えないダメージ」 / Unforeseen "hidden burdens" of raising children.
pauli
2
330
_第4回__AIxIoTビジネス共創ラボ紹介資料_20251203.pdf
iotcomjpadmin
0
140
[Neurogica] 採用ポジション/ Recruitment Position
neurogica
1
130
アプリにAIを正しく組み込むための アーキテクチャ── 国産LLMの現実と実践
kohju
0
230
2025-12-18_AI駆動開発推進プロジェクト運営について / AIDD-Promotion project management
yayoi_dd
0
160
ハッカソンから社内プロダクトへ AIエージェント「ko☆shi」開発で学んだ4つの重要要素
sonoda_mj
6
1.7k
Featured
See All Featured
Data-driven link building: lessons from a $708K investment (BrightonSEO talk)
szymonslowik
1
860
The browser strikes back
jonoalderson
0
130
The Organizational Zoo: Understanding Human Behavior Agility Through Metaphoric Constructive Conversations (based on the works of Arthur Shelley, Ph.D)
kimpetersen
PRO
0
200
Producing Creativity
orderedlist
PRO
348
40k
Cheating the UX When There Is Nothing More to Optimize - PixelPioneers
stephaniewalter
286
14k
AI: The stuff that nobody shows you
jnunemaker
PRO
1
26
SEOcharity - Dark patterns in SEO and UX: How to avoid them and build a more ethical web
sarafernandez
0
89
Kristin Tynski - Automating Marketing Tasks With AI
techseoconnect
PRO
0
110
Deep Space Network (abreviated)
tonyrice
0
22
Navigating the Design Leadership Dip - Product Design Week Design Leaders+ Conference 2024
apolaine
0
130
JAMstack: Web Apps at Ludicrous Speed - All Things Open 2022
reverentgeek
1
300
Fireside Chat
paigeccino
41
3.8k
Transcript
Python是否适合高性能web开发 温铭
高性能服务端的要素 • 多:高并发,支撑用户多 • 快:单个请求处理速度快 • 易:易开发,易维护,方便调岗和招人
技术实现 • 高并发:异步 • 处理快:缓存,减少IO • 易开发:库,只用关心逻辑
通用的架构 • Nginx -> py -> memcached(redis) -> mysql •
同步 • 跨服务器请求
理想的架构 • 异步、同步语法 • 多级缓存:进程、本机kv、跨服务器kv、 DB • 没有网络IO
现实:异步 • Tornado:第三方库齐全,回调 • Gevent:不改代码 • Asyncio New in python
3.4
现实:缓存 • functools.lru_cache New in version 3.2
Python的优势 • 丰富的库 • 开发快 • 易上手
嫁接 • Python + ?
嫁接 • Openresty:替换nginx,提供异步和共享缓 存 • Nginx -> py -> memcached(redis)
-> mysql • openresty-> py -> cache(openresty ) -> kv(openresty ) -> mysql(openresty )
自己写服务端? • 用户注册、登录 • 短信通知 • 消息推动 • 聊天 •
存储 • 支付 • …
不用写服务端 • Parse • LeanCloud(AVOS)
Q&A