Uh oh!
There was an error while loading. Please reload this page.
.NET: support hierarchial partition key on CosmosDB Actor Storage - #425
.NET: support hierarchial partition key on CosmosDB Actor Storage#425Korolev Dmitry (DeagleGross) wants to merge 27 commits into
Conversation
There was a problem hiding this comment.
Pull Request Overview
This PR introduces support for hierarchical partition keys in CosmosDB Actor Storage by changing from a single partition key (/actorId) to a composite partition key using both /actorType and /actorKey. The changes also update Aspire packages to their latest versions.
- Implements hierarchical partition key support for better data distribution and query performance
- Updates composite indexing to align with the new partition key structure
- Updates Aspire package versions to 9.4.1
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| LazyCosmosContainer.cs | Updates partition key configuration from single /actorId to hierarchical /actorType and /actorKey, and adjusts composite indexing accordingly |
| CosmosTestFixture.cs | Updates test fixture to use the new hierarchical partition key configuration |
| Directory.Packages.props | Updates Aspire package versions from 9.3.1/9.4.0 to 9.4.1 |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
….Agents.Runtime.Storage.CosmosDB.Tests/CosmosTestFixture.cs
Aspire 9.4 for the win! Looks good, is this something we can test at all or does the SDK abstract this away entirely when you're querying? |
Korolev Dmitry (DeagleGross)
commented
Aug 18, 2025
I dont think there is an easy way to test hierarchial partition keys in terms of performance: we would need to generate synthetic data; fill it in db and do the perf queries - so I think we can avoid it at this moment honestly. SDK is abstracting the partition keys, because it allows querying and posting data as before without any changes. |
Korolev Dmitry (DeagleGross)
commented
Aug 20, 2025
skipping 3 tests from the cosmos suite - the tests are stable and passed the run for 3 times in a row already. |
Korolev Dmitry (DeagleGross)
commented
Aug 21, 2025
is a part of #402 as well and merged already! |
Support more complex partition key on cosmosdb. Updated packages as well.
Also fixes#356 where test projects for CosmosDB were removed. I've added them back (recreated to make build on new VS work) and also set the CosmosDB emulator in the CI.
Fixes#305
Contribution Checklist