Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
ポケモン1000件取得が 5.29秒から0.64秒になった
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
keigo
October 30, 2026
13
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
ポケモン1000件取得が 5.29秒から0.64秒になった
keigo
October 30, 2026
Transcript
9 slides
ポケモン1000件取得が 5.29秒から0.64秒になった
作ったもの 1000匹のポケモンを検索、表示することができます
技術スタック フロントエンド:React(TypeScript) バックエンド:Hono(TypeScript) キャッシュDB:Redis API:PokeAPI
アーキテクチャ Dockerコンテナ キャッシュがある場合 ブラウザ Dockerコンテナ → ← React (フロントエンド )
Dockerコンテナ → ← Hono(Node.js) (バックエンド ) キャッシュがない場合 Redis (キャッシュ ) 外部API PokeAPI
キャッシュの効果 # バックエンドの処理時間 キャッシュなし:5.29秒 キャッシュあり:0.64秒
なぜ速いのか - Redisがインメモリデータベースだから - 1000件まとめて保存しているから
ハマったところ 並列で1000件同時にリクエストを送ったら fetch failed になった →並列10件×100回に変更
学び・気づき 今回はRedisのセットアップから実装まで全て公式の英語ドキュメントを読んで実践し た。 今まではQiitaやZennの日本語記事に頼っていたが、公式ドキュメントへの苦手意識を なくしたかった。
まとめ ・キャッシュすれば速くなる ・頑張れば英語が読める
More Decks by keigo
See All by keigo
AIに任せる処理、 任せなくていい処理
keikeigo
0
4
APIとは?
keikeigo
0
14
種族値合計600以上のポケモンを返すAPIをクリーンアーキテクチャで作成した
keikeigo
0
8
WebアプリをDockerで動かしてみた
keikeigo
0
18
Featured
See All Featured
For a Future-Friendly Web
brad_frost
184
11k
Mobile First: as difficult as doing things right
swwweet
225
10k
Measuring & Analyzing Core Web Vitals
bluesmoon
9
1.1k
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
35
2.9k
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
PRO
203
77k
YesSQL, Process and Tooling at Scale
rocio
174
15k
The Curious Case for Waylosing
cassininazir
1
630
Exploring the relationship between traditional SERPs and Gen AI search
raygrieselhuber
PRO
4
4.4k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
234
18k
The B2B funnel & how to create a winning content strategy
katarinadahlin
PRO
1
620
Navigating the Design Leadership Dip - Product Design Week Design Leaders+ Conference 2024
apolaine
2
530
Java REST API Framework Comparison - PWX 2021
mraible
34
9.8k