Added Hierarchical Partition Key Support#23919
Merged
sajeetharan merged 9 commits intoAzure:mainfrom Feb 2, 2023
Merged
Conversation
79df02f to
5014b4f
Compare
a89af0d to
8ad5527
Compare
topshot99
reviewed
Nov 23, 2022
topshot99
reviewed
Nov 23, 2022
topshot99
reviewed
Nov 23, 2022
topshot99
reviewed
Nov 30, 2022
joheredi
reviewed
Dec 10, 2022
joheredi
reviewed
Dec 10, 2022
2. refactored constuctor of Item.
e697d1b to
076765b
Compare
Collaborator
|
API change check APIView has identified API level changes in this PR and created following API reviews. |
joheredi
reviewed
Jan 11, 2023
joheredi
reviewed
Jan 11, 2023
joheredi
reviewed
Jan 11, 2023
joheredi
reviewed
Jan 11, 2023
joheredi
reviewed
Jan 11, 2023
kirankumarkolli
approved these changes
Jan 24, 2023
sajeetharan
pushed a commit
that referenced
this pull request
Feb 9, 2023
Reverts #23919 These changes are reverted so that "Hierarchical Partition Feature" can be released separately as a beta package to selected customers. These changes will be merged to main trunk after the 'beta testing' phase.
This was referenced Feb 24, 2024
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Packages impacted by this PR
@azure/cosmos
Issues associated with this PR
#23416
Describe the problem that is addressed by this PR
Added Hierarchical Partition Key Support
type PartitionKey = PartitionKeyDefinition | string | number | unknown;type PartitionKey = PrimitivePartitionKeyValue | PrimitivePartitionKeyValue[];a) Separating out
PartitionKeyDefinition[May seem like a breaking change. But the actual functions which needPartitionKeyDefinitionwere always takingPartitionKeyDefinitionas an input i.e.ContainerDefinition, the existing definition seems confusing.]b) Removal of
unknownfrom definition (along with addingboolean). Defining it asPartitionKeyDefinition | string | number | unknownwas effectively equivalent tounknown, since or of anything withunknownisunknown. Which essentially means we had no structure uponPartitionKey. This seems like a huge bug.PartitionKeyInternalto create a boundary beyond withPartitionKeywould be sanitized. The idea is to useClientContextas that boundary.Operation/OperationInputDTOs partitionKey field toPartitionKeytype.partitionKeyfor an operation during bulk api. Now if the user has providedpartitionKeyinOperationInputit will be used, if not it will be derived from resource body (for create and upsert).MultiHashcalculation.FeedOption.partitionKeyfiled toPartitionKeytype.[[Bugs fixes]]
What are the possible designs available to address the problem? If there are more than one possible design, why was the one in this PR chosen?
Are there test cases added in this PR? (If not, why?)
Yes
Provide a list of related PRs (if any)
Command used to generate this PR:**(Applicable only to SDK release request PRs)
Checklists