~/talk

Performance tuning for Azure Cosmos DB

Talkat CPH DevFest 2024 · 2024-08-26..08-30· [databases]
slides:none on file

Cosmos DB physical partitions cap at 50 GB / 10,000 RU per physical partition, so bad partition keys blow up cost and scale — ChatGPT drove ~25,000 partitions for ChatGPT (Nov 2023). Use point reads when you have id+partitionKey (about point read=~1 RU vs query~2.3 RU in the demo), prefer direct TCP from .NET SDK 3.x, reuse a singleton client, use change feed + Azure Functions to duplicate by alternative partition key, enable patch operations (id+pk required), computed properties and dedicated gateway caching cut RU and bandwidth.

AI-written summary · about

  1. 0:00Cosmos DB performance tuning
  2. 1:09Physical partitions in Cosmos DB
  3. 6:50Partition key selection
  4. 8:12Fixing cross-partition queries
  5. 10:16Optimizing point read queries
  6. 11:42Gateway vs Direct modes
  7. 14:59Dedicated Gateway mode
  8. 19:15Aggregations in Cosmos DB
  9. 21:21SDK configuration
  10. 22:45Stream API serialization
  11. 24:08DocumentClient best practices
  12. 26:11Metadata requests
  13. 27:16Bulk operations optimization
  14. 28:20Partial document updates
  15. 30:49Indexing strategies
  16. 37:51Computed properties
  17. 39:13Provisioned vs autoscaling vs serverless
  18. 41:46Reserve capacity
  19. 42:51Priority-based execution
  20. 45:03VS Code extension demo
  21. 49:22Q&A
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.