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
ELB vs API Gateway vs CloudFront / 結局何を選べばいいの?
Search
haruko_tanabe
January 28, 2025
350
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
ELB vs API Gateway vs CloudFront / 結局何を選べばいいの?
haruko_tanabe
January 28, 2025
More Decks by haruko_tanabe
See All by haruko_tanabe
ELB vs API Gateway vs CloudFront / 結局何を選べばいいの?
harukotanabe
1
470
TerraformでS3バケット削除後、再作成するとApplyが終わらない!
harukotanabe
0
150
エンジニア歴1年未満の初心者が3か月でAWS認定試験を全冠した話
harukotanabe
1
7.8k
クラウド未経験者が3か月でAWS認定試験を全冠した話
harukotanabe
0
350
エンジニア歴1年未満の初心者が3か月でAWS認定試験を全冠した話
harukotanabe
0
200
Featured
See All Featured
The B2B funnel & how to create a winning content strategy
katarinadahlin
PRO
1
540
ReactJS: Keep Simple. Everything can be a component!
pedronauck
666
130k
From π to Pie charts
rasagy
1
380
Done Done
chrislema
187
17k
YesSQL, Process and Tooling at Scale
rocio
174
15k
KATA
mclloyd
PRO
35
16k
[Rails World 2026] Durable orchestration on Rails: from continuation to workflow
palkan
1
330
30 Presentation Tips
portentint
PRO
1
410
Leading Effective Engineering Teams in the AI Era
addyosmani
9
2.6k
The Curse of the Amulet
leimatthew05
3
15k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
50
10k
Principles of Awesome APIs and How to Build Them.
keavy
128
18k
Transcript
ELB vs API Gateway vs CloudFront 結局何を選べばいいの? 2025/1/28 tanabe haruko
• アクセンチュア株式会社のエンジニア • 2024 Japan AWS All Certifications Engineers •
Google Cloud認定資格 11種保有 tanabe haruko https://zenn.dev/haruko_tanabe @hrsaaaam
アジェンダ 1. はじめに 2. 各サービスの利用目的 3. 各構成パターンとユースケース 4. まとめ
1 はじめに
はじめに • エンジニア経験が浅いと、インフラアーキテクチャの検討は難易度が高い。 ➢ どのようなケースで、どのサービスを採用すればよいのか判断するための 指針がほしい! • Elastic Load BalancingやAmazon
API Gateway、Amazon CloudFrontは、「アプリケーションのフロントに置き、ユーザーからのアクセ スを受け付ける」という点は共通しているが、それぞれ本質的な目的は異な る。
2 各サービスの利用目的
各サービスの利用目的(1/3) 1. Elastic Load Balancing(ELB) ➢ 1つまたは複数のAZ内の複数のターゲット の ヘルスチェックを行い、受信したトラフィックを 正常なターゲットにのみ自動的に分散させる
ことが目的。 https://docs.aws.amazon.com/ja_jp/elasticloadbalancing/latest/userguide/how-elastic-load-balancing-works.html
各サービスの利用目的(2/3) 2. Amazon API Gateway ➢ あらゆる規模のREST、HTTP、およびWebSocket APIを作成、公開、維持、 モニタリング、およびセキュア化することが目的。 https://docs.aws.amazon.com/ja_jp/apigateway/latest/developerguide/getting-started.html
各サービスの利用目的(3/3) 3. Amazon CloudFront ➢ エッジロケーションを経由し、コンテンツを キャッシュ・圧縮することによって、世界中の ユーザーへ低レイテンシーなコンテンツの配 信を実現することが目的。 https://docs.aws.amazon.com/ja_jp/AmazonCloudFront/latest/DeveloperGuide/Introduction.html
3 各構成パターンとユースケース
各構成パターンとユースケース(1/2) Public AWS Cloud Region VPC Private ア プ リ
ALB Cloud Front Public AWS Cloud Region VPC Private ア プ リ ALB ELB(ALB) ELB(ALB) + CloudFront 構成図 ユースケース パフォーマンス コスト ✓ 複数のEC2インスタンスやコンテナベースのWebアプリケーションを バックエンドとして、ヘルスチェックを行いながらリクエストを均一に ルーティングしたい場合。 ✓ ALBの機能に加え、世界中のユーザーに対して低レイテンシーな コンテンツ配信を行いたい場合。 ✓ キャッシュの有効期限や、Invalidation機能を細かく設定したい 場合。 ✓ 実行利用時間に応じた課金体系であるため、アクセス数には影 響されない。 ✓ リクエスト数、及びエッジロケーションからのデータ転送量に応じた課 金体系。 ✓ キャッシュ機能が無いため、CloudFrontと比較するとレイテンシー は高い。 ✓ エッジロケーションでキャッシュを作成できるため、低レイテンシーを 実現可能。
各構成パターンとユースケース(2/2) ELB(NLB) + API Gateway ELB(NLB) + API Gateway +
CloudFront 構成図 ユースケース パフォーマンス コスト ✓ 受信したAPIコール数に応じた課金体系のため、アクセス数に影 響される。 ✓ CloudFrontには及ばないが、キャッシュやペイロード圧縮により最 適化が可能。 AWS Cloud Region VPC Private Public ア プ リ NLB API Gateway Cloud Front AWS Cloud Region VPC Private Public ア プ リ NLB API Gateway ✓ モニタリングや変換、アクセスの上限数のコントロール、バージョニン グ等の機能と併せてAPIを構築・統合管理したい場合。 ✓ API課金や、 AWS Cognitoと連携した認証/認可の仕組みを 利用したい場合。 ✓ API Gatewayの機能に加え、世界中のユーザーに対して低レ イテンシーなコンテンツ配信を行いたい場合。 ✓ キャッシュの有効期限や、Invalidation機能を細かく設定したい 場合。 ✓ キャッシング効果により、アクセス数が多いほど、コスト削減につなが りやすい。 ✓ エッジロケーションでキャッシュを作成できるため、低レイテンシーを実 現可能。
4 まとめ
まとめ • アプリケーションに求められる要件(ルーティング、セ キュリティレベル、レスポンス速度、等)によって、適し たサービスが存在する。 • その他詳細は以下記事参照。 https://zenn.dev/acntechjp/articles/8bde90d02ff2ef
Thank you!