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

Discriminator should be read-only #21154

Closed
AndriySvyryd opened this issue Jun 6, 2020 · 2 comments · Fixed by #21796
Closed

Discriminator should be read-only #21154

AndriySvyryd opened this issue Jun 6, 2020 · 2 comments · Fixed by #21796
Labels
area-model-building breaking-change closed-fixed The issue has been fixed and is/will be included in the release indicated by the issue milestone. type-enhancement
Milestone

Comments

@AndriySvyryd
Copy link
Member

No description provided.

@ajcvickers
Copy link
Member

Make discriminator read-only by default, but allow explicit configuration back to read-write.

@lajones
Copy link
Contributor

lajones commented Jul 9, 2020

Note: after discussion with @ajcvickers the comment above does not mean "add an API on DiscriminatorBuilder which would call down and make the property read-write"; it means "rely on existing APIs to do that, whether that's Metadata API or some sugar we add later to allow any property to be set read-write if it is currently read-only, just don't implement this issue in such a way that it makes the discriminator's property never be settable to read-write". (Extra note: looks like we already have that sugar - see IConventionPropertyBuilder.BeforeSave and .AfterSave).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-model-building breaking-change closed-fixed The issue has been fixed and is/will be included in the release indicated by the issue milestone. type-enhancement
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants