Skip to content

Commit e0e1e5c

Browse files
committed
Edited release notes for 2.0.0-rc1.
1 parent 5442c31 commit e0e1e5c

File tree

1 file changed

+23
-9
lines changed

1 file changed

+23
-9
lines changed

Release Notes/Release Notes v2.0.0.md

Lines changed: 23 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
C#/.NET Driver Version 2.0.0-beta3 Release Notes
2-
==========================================
1+
C#/.NET Driver Version 2.0.0-rc1 Release Notes
2+
==============================================
33

44
(Preliminary)
55

@@ -39,34 +39,42 @@ New Api
3939

4040
Because of our async nature, we have rebuilt our entire API. The new API is accessible via MongoClient.GetDatabase.
4141

42-
- Interfaces are used (IMongoClient, IMongoDatabase, IMongoCollection<T>) to support easier testing.
42+
- Interfaces are used (IMongoClient, IMongoDatabase, IMongoCollection&lt;TDocument&gt;) to support easier testing.
4343

4444
- A fluent Find API is available with full support for expression trees including projections.
45+
46+
```csharp
4547
var people = await db.GetCollection<Person>("people")
4648
.Find(x => x.FirstName == "Jack")
4749
.SortBy(x => x.Age)
4850
.Projection(x => x.FirstName + " " + x.LastName)
4951
.ToListAsync();
52+
```
5053

5154
- A fluent Aggregation API is available with mostly-full support for expression trees (Unwind is special).
55+
56+
```csharp
5257
var people = await db.GetCollection<Person>("people")
5358
.Aggregate()
5459
.Match(x => x.FirstName == "Jack")
5560
.GroupBy(x => x.LastName, g => new { _id = g.Key, TotalAge = g.Sum(x => x.Age)})
5661
.ToListAsync();
62+
```
5763

5864
- Support for dynamic.
65+
66+
```csharp
5967
var person = new ExpandoObject();
6068
person.FirstName = "Jane";
6169
person.Age = 12;
6270
person.PetNames = new List<dynamic> { "Sherlock", "Watson" }
6371
await db.GetCollection<dynamic>("people").InsertOneAsync(person);
72+
```
6473

65-
66-
Expirimental Features
74+
Experimental Features
6775
=====================
6876

69-
One expirimental feature has been introduced while we work through the best API both for us and for the community
77+
One experimental feature has been introduced while we work through the best API both for us and for the community
7078
of other drivers. As such, it is public and we welcome feedback, but should not be considered stable and we will not make
7179
a major version bump when/if they are changed.
7280

@@ -82,7 +90,8 @@ are some that may affect a greater number of people:
8290

8391
- .NET 3.5 and .NET 4.0 are no longer supported. If you still must use these platforms, then the 1.x series of the driver will continue to be developed.
8492

85-
- The nuget package mongocsharpdriver now includes the legacy driver. It includes 3 new nuget packages, MongoDB.Bson, MongoDB.Driver.Core, and MongoDB.Driver. MongoDB.Driver is the replacement for mongocsharpdriver.
93+
- The nuget package mongocsharpdriver now includes the legacy driver. It depends on 3 new nuget packages, MongoDB.Bson, MongoDB.Driver.Core,
94+
and MongoDB.Driver. MongoDB.Driver is the replacement for mongocsharpdriver.
8695

8796
- We are no longer strong naming (CSHARP-616) our assemblies. Our previous strong naming was signed with a key in our public repository. This did
8897
nothing other than satisfy certain tools. If you need MongoDB assemblies to be strongly named, it is relatively straight-forward to build the
@@ -95,10 +104,15 @@ assemblies yourself.
95104
- MongoServer is a deprecated class. Anyone using MongoClient.GetServer() will encounter a deprecation warning and, depending on how your build is
96105
setup, may receive an error. It is still safe to use this API until your code is ported to the new API.
97106

98-
- Improved the BsonSerializer infrastructure (CSHARP-933). Anyone who has written a custom serializer will be affected by this. The changes are minor, but were necessary to support dynamic serializers as well as offering great speed improvements and memory management.
107+
- Improved the BsonSerializer infrastructure (CSHARP-933). Anyone who has written a custom serializer will be affected by this. The changes are minor,
108+
but were necessary to support dynamic serializers as well as offering great speed improvements and improved memory management.
99109

100110
- ReadPreference(CSHARP-1043) and WriteConcern(CSHARP-1044) were rewritten. These classes are now immutable. Any current application
101111
code that sets values on these classes will no longer function. Instead, you should use the With method to alter a ReadPreference or WriteConcern.
102112
var writeConcern = myCurrentWriteConcern.With(journal: true);
103113

104-
- Dynamic DictionaryRepresentation (CSHARP-939) has been removed. Its intent was to store, in some manner, anything in a .NET dictionary. In practice, this leads to the same values getting stored in different ways depending on factors such as a "." inside the key name. We made the decision to eliminate this variability. This means that documents that used to serialize correctly may start throwing a BsonSerializationException with a message indicating the key must be a valid string. CSHARP-1165 has a solution to this problem. It should be noted that we will continue to read these disparate representations without error.
114+
- Dynamic DictionaryRepresentation (CSHARP-939) has been removed. Its intent was to store, in some manner, anything in a .NET dictionary. In practice,
115+
this leads to the same values getting stored in different ways depending on factors such as a "." inside the key name. We made the decision to
116+
eliminate this variability. This means that documents that used to serialize correctly may start throwing a BsonSerializationException with a message
117+
indicating the key must be a valid string. CSHARP-1165 has a solution to this problem. It should be noted that we will continue to read these disparate
118+
representations without error.

0 commit comments

Comments
 (0)