-
Notifications
You must be signed in to change notification settings - Fork 36
EF-76: Flow EF metadata down through CreateGetValueExpression #240
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
EF-76: Flow EF metadata down through CreateGetValueExpression #240
Conversation
That is, the IProperty or INavigation associated with the access. Types, requiredness, type-mappings, etc. are then obtained from the property. An alias is passed in if the name in the BSON document is different from the mapped element name for the property.
|
There is an existing patch(es) for this commit SHA: Please note that the status that is posted is not in the context of this PR but rather the (latest) existing patch and that may affect some tests that may depend on the particular PR. If your tests do not rely on any PR-specific values (like base or head branch name) then your tests will report the same status. If you would like a patch to run in the context of this PR and abort the other(s), comment 'evergreen retry'. |
| } | ||
|
|
||
| internal static BsonSerializationInfo GetPropertySerializationInfo(IReadOnlyProperty property) | ||
| internal static BsonSerializationInfo GetPropertySerializationInfo(string? alias, IReadOnlyProperty property) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should make the alias optional and come after property rather than passing null in some paths.
| if (property != null) | ||
| { | ||
| serializationInfo = BsonSerializerFactory.GetPropertySerializationInfo(property); | ||
| serializationInfo = BsonSerializerFactory.GetPropertySerializationInfo(null, property); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Then this won't need to change. No alias, no argument.
| private static void WriteProperty(IBsonWriter writer, object? value, IProperty property) | ||
| { | ||
| var serializationInfo = BsonSerializerFactory.GetPropertySerializationInfo(property); | ||
| var serializationInfo = BsonSerializerFactory.GetPropertySerializationInfo(null, property); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same here.
5513a93
into
mongodb:feature-select-projections
…b#240) * EF-76: Flow EF metadata down through CreateGetValueExpression That is, the IProperty or INavigation associated with the access. Types, requiredness, type-mappings, etc. are then obtained from the property. An alias is passed in if the name in the BSON document is different from the mapped element name for the property. * Updates based on co-pilot review.
* EF-76: Flow EF metadata down through CreateGetValueExpression That is, the IProperty or INavigation associated with the access. Types, requiredness, type-mappings, etc. are then obtained from the property. An alias is passed in if the name in the BSON document is different from the mapped element name for the property. * Updates based on co-pilot review.
That is, the IProperty or INavigation associated with the access. Types, requiredness, type-mappings, etc. are then obtained from the property.
An alias is passed in if the name in the BSON document is different from the mapped element name for the property.