4. GDC 2022 にて紹介された様々なストーリー
PlayFab
UGC
Live Ops
UGC
PlayFab
PMLP
Multiplayer
Services
PlayFab
MPS
Global Game
Servers
Azure
Kubernete
s
Global Game
Servers
PlayFab
Experime
nts
Live Ops -
Experiments
10. No Manʼs Sky
• インフラチームの特徴
• 少⼈数
• クラウドの設計 ( Azure + PlayFab )
• C# on Azure PaaS
• NoSQL として Cosmos DB を採⽤
• ⾮同期のデータ書き込み (Event Hub)
• ⼤量データ(3TB)
• クラウドの設計 (PlayFab)
• Xbox スマートマッチ から
クロスプレイマッチメイキング へ
10
How No Man's Sky Used Azure to Share an Infinite Universe
| Develop:Brighton 2021
11. ユニークな点は Event Hub と Cosmos DB の組み合わせ
11
• アプリは、App Service で C#を運⽤
• Azure Event Hubs によるデータベース負荷軽減データベースの状態に関係なくデータの更新を⾏う
• Cosmos DBによる⾃動拡張により3テラバイトのデータを運営
• Azure Table Storage は Cosmos DBの補助として利⽤(パーティション負荷軽減)
• 当初はWindows アプリ → 運営中にLinuxに移⾏ (.NET Core 1 -> .NET 5)
• Xbox Smart Match から、PlayFabのクロスプラットフォームマッチに変更
App Service
サーバーアプリ(C#)
ケーション
Event Hub
Cosmos DB
Azure Table
Storage
12. Fall Guys: Ultimate Knockout
12
"Fall Guys exceeded all expectations at launch. It sold
more than 11 million copies on Steam alone and
ranked as the most downloaded PlayStation Plus
title ever. Azure provided all the reassurance we
needed to scale elastically and quickly."
Adam Fletcher: Chief Technology Officer
Tonic Games Group
「Fall Guysは発売時にすべての期待を上回りました。
Steamだけで1100万本以上を販売し、これまでで
最もダウンロードされたPlayStation Plusタイトル
としてランク付けされました。Azure は、弾⼒性
と迅速なスケーリングに必要なすべての安⼼感を
与えてくれました。
アダム・フレッチャー:最⾼技術責任者
トニックゲームグループ
主な Azure 機能
• Azure Kubernetes Services (AKS)
• Azure Cosmos DB
• Azure DDoS Protection
• Azure DevOps
Azure
Kubernetes
Services
(AKS)
Azure
Cosmos
DB
14. K8S、NoSQL、DDoS対策
の評価ポイント
Kubernetes クラスターのコンテナー サービス
ダウンタイムなしで迅速に拡張できるマルチモデル
NoSQL データベース
ゲームプラットフォームに対する分散型サービス拒
否(DDoS)攻撃を検出して軽減するためのソ
リューション
ソフトウェア開発とIT運⽤
14
AKS Cluster
Pod Pod Pod
Pod Pod Pod
Pod Pod Pod
Pod Pod Pod
Pod Pod Pod
Pod Pod Pod
Kubernetes クラスターのメリットの例
1. コンテナ⼿動スケール/オートスケール
2. 環境構築と廃棄が楽、早い
1. ブルー/グリーンデプロイメント
2. 使い捨てシステム
3. アプリの配布・展開が楽、早い
4. 依存関係地獄から解放される
1. 複数のランタイム/ライブラリーを同居可能
5. ⾃動ローリングアップデート/ロールバック
6. コンテナの(再)スケジュール
7. 障害ノード上のコンテナの⾃動復旧
17. Forza Horizon 5
With our compute, storage, and data stacks all
on Azure, our engineering teams can now
spend more time building new experiences
for our players rather than managing our
infrastructure.
Daniel Adent: General Manager of ForzaTech
Turn 10 Studios
コンピューティング、ストレージ、データ スタックがすべて
Azure 上にあるため、エンジニアリング チームは、イ
ンフラストラクチャを管理するのではなく、プレイヤー
向けの新しいエクスペリエンスの構築により多くの時
間を費やすことができます。
ダニエル・エイデント:ForzaTechのゼネラルマネージャー
ターン10スタジオ
17
主な Azure 機能
• Azure Kubernetes Services
(AKS)
• Azure Cache for Redis
• Azure Storage
Azure
Kubernetes
Services
(AKS)
Azure
Cache
for Redis
19. Azure managed control plane
API server
Controller
Manager
Scheduler
etcd
Store
Cloud
Controller
Self-managed master node(s)
User
Schedule pods over
private tunnel
Kubernetes
API endpoint
App/
workload
definition
YAML/JSON
or
Containerd
Pods
Containerd
Pods
kubelet
kube-proxy
Containerd
Pods
Containerd
Pods
kubelet
kube-proxy
Customer VMs(VMSSによるクラスタリング)
AKSは、Windows コンテナ も OK︕
Forza Horizon 5 のアプリは Windows で開発していた
⾃動アップグレード、パッチ
⾼安定性、可⽤性
安全なクラスタースケーリング
セルフヒーリング
コントロールプレーンのAPIサーバーモニタリング
コントロールプレーンに対するコストはゼロ
→ ノードをゼロにすることも可能
→ SLAが必要な場合は、別料⾦
VMSSを使ったノード、ノードプールの管理
20. Forza Horizon 5 で採⽤されたマイクロサービスアプローチ
① AKS上に17のマイクロサービスを展開
② プレイヤーからのトラフィックはALB経由で Aggregator Podが処理
③ AKSの2つのスケール機能
→ クラスターオートスケーラー
→ ⽔平 Pod オートスケーラー
④ キャッシュとしてAzure Cache for Redis を活⽤
⑤ キャッシュのスケールが必要な場合、Azure Storageを活⽤して
Shading を実施し、パフォーマンスを確保
⑥ Config は ConfigMap に、Secrets は Secretsに保存
⑦ PlayFab との連携
21. Forza Horizon 5 : オンプレミスからの段階移⾏の歴史
On-prem VMs
Windows Server
IIS
.NET framework
Ranking
App
Auction
App
GrageMng
Apps
Azure VMSS(AKS)
Windows
Server
Container
.NET
framework
Ranking
App
Windows
Server
Container
.NET
framework
Auction
App
Windows
Server
Container
.NET
framework
GrageMng
App
😫必要な時に設備増強
😫スケールに限界
😐必要な時にスケール可能
😐パフォーマンスとコスト最適化が進む
😊マイクロサービス化により個別にスケール
😊パフォーマンスとコストの更なる最適化
🤔スケール時の課題
Old New
Azure
Windows Server
IIS
.NET framework
Ranking
App
Auction
App
GrageMng
Apps
Azure Virtual Machine
Azure Cloud
Service
(App PaaS)
.NET
framework
Some
Apps
29. Microsoft Azure を使うことで、
私たちのチームは、アーキテクチャ、容量、構成を気にすることなく、
新しい機能やサービスの提供に重点を置いています。
私たちは Azure をバックエンド システムのブレーンにしました。
“With Microsoft Azure, our team focuses on providing new features and services instead of worrying about
architecture, capacity, or configuration. We’ve made Azure the brains of our back-end system.”
Dmitri Brevdo
Lead Backend Developer, Saber Interactive
29
37. 補⾜: アプリケーションモダナイゼーションの戦略カテゴリ
実装するロジック インフラ要件概要 クラウドの選択
Game Server ゲームの通信を⾏う。MMOの
空間情報、MOのゲームルーム、
などを実現。
UDP/TCPによる通信を⾏う
1秒の停⽌も許容できない場合が
ある
Azure(本体): IaaS (VM) / AKS / ACI
Azure(オーケストレーション): Functions
PlayFab: MPS
Game Service 認証やマスターデータ、プレ
イヤーのステートデータ、ス
タティスティックス情報の更
新などを⾏うウェブサーバー
HTTP Rest API または gRPC を
⽤いたウェブAPIサーバー
Azure: WebApps / Functions / AKS / ACA
PlayFab: PlayFab LiveOps
Game DB 主にGame Service のデータの
永続化を⾏うデータベース
Game Serverや、
Matchmaking、Chatのログ解
析なども⾏う
多数の同時接続が必要な場合は
NoSQL
複雑なクエリーが想定される場合
は RDB を利⽤
Azure: SQL DB / MySQL / CosmosDB
PlayFab: PlayFab LiveOps
Matchmaking プレイヤー同⼠の対戦相⼿を
決定するためのロジック
コンソールゲームの場合は複雑な
カスタムロジックを実装すること
が多い
Azure: Functions
PlayFab: PlayFab Matchmaking
Chat プレイヤー同⼠がテキストや
⾳声チャットを⾏う
WebSocket のような全⼆重通信
を利⽤する
Azure: SignalR Service / Web PubSub
PlayFab: PlayFab Party
38. Connectivity
United States
United States
Canada
Mexico
Venezuela
Colombia
Peru
Bolivia
Brazil
Argentina
Atlanta
Ocean
Algeria
Mali
Niger
Nigeria
Chad
Libya Egypt
Sudan
Ethiopi
a
Dr
Congo
Angola
Zambia
Nambia
South
Africa
Greenland
Svalbard
Sweden
Norway
United
Kingdom
France
Poland
Ukraine
Turkey
Saudi
Arabia
Iran
Kazakistan
India
Russia
Russia
China
Myanmar
(Burma)
Indian
Ocean
Indonesia
Australia
Pacific
Ocean
Pacific
Ocean
Data
center
Owned Capacity
Moving to Owned
Leased Capacity
Edge Site
Azure Data Center
世界最大級のネットワーク
• 8,000以上のISPセッション
• 130以上のエッジサイト
• 44 Express Route
• 33,000マイル(lit fiber)
• SDN マネージド (SWAN、OLS)
DCs and Network sites not exhaustive
1 つのリージョン内で、HA=高可用性を担
保するためには、 2 つのオプションがある。
遅延時間も変わるので、ゲームの応答時間
のテスト・評価をお忘れなく。
可用性セット (AS)
or
可用性ゾーン (AZ)
39. Load Balancer - Standard
VMSS spans Zones
Load balancing across zones
Zone resilient VIPs
Single DNS name
VMSS limited to 1000 instances
Traffic Manager
VMSS per Zone
TM profile for High Availability
Zonal VIP / VMSS
DNS name for cross-zone VMSS
Availability Zones
with Traffic Manager & Load Balancer
Availability Zone を跨ぐ
VMSS スケールアウト
Azure の ロードバランサーは、
可用性ゾーンのシナリオをサ
ポートしています
(複数のゾーンに分散)
参考ドキュメント
• ロードバランサーと可用性ゾーン
• リージョン間 LB (プレビュー)
• LBと VMSSの規則の追加
Azure 仮想マシンスケールセット(VMSS)は、
Azure Compute Gallery(旧称:Shared Image
Gallery)を通じて、標準のマーケットプレイス
イメージとカスタムイメージについて、最大
1,000 VMインスタンスをサポートします
マネージドイメージを使用してスケールセット
を作成する場合、上限は600VMインスタンスで
す
スケールセットを展開するとき、可用性ゾーン
ごとに1つの配置グループを使用するか、ゾーン
ごとに複数の配置グループを使用するかを選択
することもできます。