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
HTML cache
Search
tsuyoshi nakamura
March 17, 2017
Business
0
660
HTML cache
HTML cache
tsuyoshi nakamura
March 17, 2017
Tweet
Share
More Decks by tsuyoshi nakamura
See All by tsuyoshi nakamura
社内の勉強会で発表した_output_一部抜粋版_.pdf
tsuyoshi
0
480
PHPを少しでも早く_条件はあるよ_.pdf
tsuyoshi
0
82
スタートアップ6年目のレビュー文化.pdf
tsuyoshi
1
1.9k
PHPを少し深堀るよ.pdf
tsuyoshi
0
370
Reactive_Manifesto.pdf
tsuyoshi
0
75
About_Resilience.pdf
tsuyoshi
1
85
エンジニアの循環ってgood_or_bad_.pdf
tsuyoshi
0
1.3k
スタートアップしてからの失敗の数々
tsuyoshi
0
2.4k
スタートアップエンジニアの役割
tsuyoshi
0
530
Other Decks in Business
See All in Business
キャンバスエッジ株式会社 会社説明資料
canvasedge
0
8.8k
AI × アジャイルで、エンタープライズを動かす:文化に寄り添い、ビジネス価値を拡大する実践知 / AI × Agile: Driving Enterprise Transformation
yosuke_matsuura
PRO
1
1.4k
会社紹介資料 / ProfileBook
gpol
5
55k
40代データ人材のキャリア戦略
pacocat
4
3.9k
エピックベース株式会社_会社概要資料_202601
takayoshimatsuda
PRO
1
530
【新卒採用資料】Natee Company Deck _202601
nateehr
0
2.7k
202601〜【合同会社プレップ湘南】COMPANY DECK
prepp
0
160
【正社員型エンジニア派遣事業】採用資料
cdcsaiyo
0
280
対立を超えてビジネス、開発、顧客が本当に欲しかったものを全両立するプロダクト組織の作り方/trade-off basic rsgt2026
moriyuya
3
7.7k
AI時代のPMに求められるマインドセット
kozotaira
1
200
株式会社Oxxx Culture Deck
oxxxinc
0
590
アットウェア 会社説明資料
atware
0
13k
Featured
See All Featured
Measuring Dark Social's Impact On Conversion and Attribution
stephenakadiri
1
120
Product Roadmaps are Hard
iamctodd
PRO
55
12k
Git: the NoSQL Database
bkeepers
PRO
432
66k
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
122
21k
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
16
1.8k
Navigating Algorithm Shifts & AI Overviews - #SMXNext
aleyda
0
1.1k
The Language of Interfaces
destraynor
162
26k
Rebuilding a faster, lazier Slack
samanthasiow
85
9.4k
Kristin Tynski - Automating Marketing Tasks With AI
techseoconnect
PRO
0
130
Making the Leap to Tech Lead
cromwellryan
135
9.7k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
31
2.7k
エンジニアに許された特別な時間の終わり
watany
106
230k
Transcript
HTML Cache Constitution 2017.03.17 社内勉強会 @nakamura_tsuyo4
Agenda ➔ Nginx proxy cache ➔ Varnish ➔ Fastcgi cache
➔ memo
Agenda ➔ Nginx proxy cache ➔ Varnish ➔ Fastcgi cache
➔ memo
Nginx proxy cache LB Nginx (proxy cache) Nginx (proxy cache)
Nginx+fastcgi Nginx+fastcgi
Nginx proxy cache LB Nginx (proxy cache) Nginx (proxy cache)
Nginx+fastcgi Nginx+fastcgi んーん
Nginx proxy cache LB Nginx (proxy cache) Nginx (proxy cache)
LB Nginx+fastcgi Nginx+fastcgi
Nginx proxy cache LB Nginx (proxy cache) Nginx (proxy cache)
LB Nginx+fastcgi Nginx+fastcgi 構成変更ありきだなぁー
Agenda ➔ Nginx proxy cache ➔ Varnish ➔ Fastcgi cache
➔ memo
Varnish LB Nginx+fastcgi Varnish LB Varnish plus? Varnish plus? Nginx+fastcgi
Varnish LB Nginx+fastcgi Varnish LB Varnish plus? Varnish plus? Nginx+fastcgi
VHA (VARNISH HIGH AVAILABILITY)
Varnish LB varnish varnish Nginx+fastcgi Nginx+fastcgi varnish LB
Varnish LB varnish varnish Nginx+fastcgi Nginx+fastcgi varnish LB Self-routing varnish
cluster
Varnish self-routing varnish cluster https://info.varnish-software.com/blog/creating-self-routing-varnish-cluster
Varnish self-routing varnish cluster config https://gist.github.com/rezan/1eadaef1745286a4e7262d83e1eff19c
Varnish self-routing varnish cluster config “ We leverage this director
to do our content “ sharding by hashing on the URL and route “ the request to its destination:
Agenda ➔ Nginx proxy cache ➔ Varnish ➔ Fastcgi cache
➔ memo
FastCGI cache LB Nginx+fastcgi fastcgi_cache Nginx+fastcgi fastcgi_cache
FastCGI cache LB Nginx+fastcgi fastcgi_cache Nginx+fastcgi fastcgi_cache 構成変更なく手軽かも
Agenda ➔ Nginx proxy cache ➔ Varnish ➔ Fastcgi cache
➔ memo
memo • Cache自体はそれぞれのサーバに保存されるので deleteしたい時の考慮は必要 ◦ Or 即時反映されなくても良い業務設計が必要 • cacheすべきurlはcache serverのconfigでの管理になる
• Proxy_cache_lock , fastcgi_cache_lockは使った方がよさげ ◦ 同時アクセス負荷がかかった時に結局死ぬと思ってる • パフォーマンスのBenchmarkは未検証 • First stepとしてfastcgi_cacheは良さげ • リアルタイム性が必要なデータは当然あるので API開発はセット