Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[release/8.0] Cosmos: Generate ordinal values for key properties that used not to be persisted. #32489

Merged
merged 2 commits into from
Jan 3, 2024

Conversation

AndriySvyryd
Copy link
Member

@AndriySvyryd AndriySvyryd commented Dec 1, 2023

Port of #32469
Fixes #32363
Fixes #32410

Description

We fixed #31664 for 8.0 RTM. It was a known breaking change, but had bigger impact then initially thought for existing databases. With that fix the nested entities fail to load when queried as the now required key value is missing. The new fix is to use a generated ordinal value in this case (this is the same value that the property would have had in 8.0.0-rc2 and previous versions).

Customer impact

Users with an existing database that use a model with nested owned collections where the entity type has an int property that matches our key convention (e.g. named Id) are either getting an exception during query execution or the nested collection is silently lost.

How found

Customers reported on 8.0

Regression

Yes

Testing

Added.

Risk

Low, reverses some of the behavior changed in a previous fix. Added a quirk for this fix and also for #31664 in case there are more scenarios not covered by the current fix.

@AndriySvyryd AndriySvyryd added this to the 8.0.2 milestone Dec 5, 2023
@wtgodbe wtgodbe merged commit 88ef9e0 into release/8.0 Jan 3, 2024
7 checks passed
@wtgodbe wtgodbe deleted the Issue32363 branch January 3, 2024 22:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants