47. products
PK: categoryId
category name?
tag names?
‘categoryId’は、カテゴリのすべての製品を非常に効率的に取得できるため、ここで
は適切な partition key といえる
しかし、今の問題は product をクエリするたびに、category ID と tag ID の塊が取
得される。
48. products
SELECT * FROM c WHERE c.categoryId = 'CategoryA'
productCategories
SELECT c.name FROM c WHERE c.id = 'CategoryA'
productTags
SELECT * FROM c
WHERE c.id IN ('<tagId1>', '<tagId2>', '<tagId3>')
176. • Getting started with Azure Cosmos DB
• Running applications with
• bursty, intermittent traffic that is hard to forecast, or
• low (<10%) average-to-peak traffic ratio
• Developing, testing, prototyping and running in production new applications where the traffic pattern is
unknown
• Integrating with serverless compute services like Azure Functions
195. Operation Request Charge Operations/sec Total
Write to container 5 RU’s 200/sec 1,000 RU / sec
SELECT TOP 1 * FROM
c WHERE c.vin =
“Z3YM…" ORDER BY
c.timestamp DESC
35 RU’s 10,000/sec 350,000 RU / sec
Operation Request Charge Operations/sec Total
Write to container 5 RU’s 200/sec 1,000 RU / sec
Update to container
with current status
9 RU’s 200/sec 1,800 RU / sec
Read current status
from container
1 RU’s 10,000/ sec 10,000 RU / sec
351,000 RU’s
12,800 RU’s
197. Subscription User Create Date …
123abc Ben6 6/17/17
456efg Ben6 3/14/17
789hij Jen4 8/1/16
012klm Joe3 3/4/17
Application
User Total Subscriptions
Ben6 2
Jen4 1
Joe3 1
198.
199. DASHBOARDS & REPORTS
EVENT HUBS
Triggered by Cosmos
Change Feed
IoT Devices: Streaming
Events
(from the data
generator)
AZURE FUNCTION COSMOS DB
AZURE FUNCTION
STREAM
ANALYTICS
EVENT HUBS
Azure SQL Database
(database that users
migrated from – data
generator pulls order
info from here)
Velocity
Concurrency
209. ユーザー
アプリ
Azure
Cosmos DB
Azure Data Lake Storage
抽出
(パイプライン)
変換 /
強化
オーケストレーション
Power BI
提供
Azure Cosmos DB から Azure Data Lake Storage に定期的にデータをイン
ジェスト
分析に最適化するために、データ形式とストレージ レイヤーを管理
Apache Spark
for Synapse
Synapse
SQL
217. Big data analytics
Data Preparation/Curation
Ad-hoc data
exploration
Find answer to unknown
questions
Azure Machine
Learning
Machine learning
Build and deploy models