-
Type:
Bug
-
Resolution: Unresolved
-
Priority:
Unknown
-
None
-
Affects Version/s: None
-
Component/s: Serialization
-
None
-
None
-
Dotnet Drivers
-
None
-
None
-
None
-
None
-
None
-
None
It seems that the `BsonElement` attribute is ignored on properties called "Id". I think this could happen because of our automaticÂ
For example :
var pipeline = new EmptyPipelineDefinition<Movie> () .Project( Builders<Movie>.Projection .Exclude(m => m.Id) ); public class Movie { [BsonElement("notId")] public ObjectId Id { get; set; } }
This will render to
{ "$project" :{ "_id" : 0 }}
instead ofÂ
{ "$project" :{ "notId" : 0 }}