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

Mark owned collections composite key properties to use generated values even after the first two usages #21042

Merged
merged 1 commit into from
Jun 1, 2020

Conversation

ajcvickers
Copy link
Member

Fixes #20932

The first time a CLR type is used as an owned collection it is not weak. Value generation is set correctly.
The second time, it becomes weak, and value generation is set correction for both usages.
The first time, it is already weak, but the FK is marked as IsOwnersShip after value generation has been set.

The fix to run the value generation convention again when FK ownership changes.

@ajcvickers ajcvickers changed the title Mark owned collections composite key properties use generated values even after the first two usages Mark owned collections composite key properties to use generated values even after the first two usages May 25, 2020
@ajcvickers ajcvickers requested a review from a team May 25, 2020 18:44
…even after the first two usages

Fixes #20932

The first time a CLR type is used as an owned collection it is not weak. Value generation is set correctly.
The second time, it becomes weak, and value generation is ste correction for both usages.
The first time, it is already weak, but the FK is marked as IsOwnersShip after value generation has been set.

The fix to run the value generation convention again when FK ownership changes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Incorrect StoreGenerationIndex is set when more than two entity types share the same owned collection
2 participants