|
| 1 | +C# Driver Version 1.6.1 Release Notes |
| 2 | +===================================== |
| 3 | + |
| 4 | +This is a minor release containing a few bug fixes, particularly related to ReadPreference support |
| 5 | +and sending commands to secondaries. |
| 6 | + |
| 7 | +An online version of these release notes is available at: |
| 8 | + |
| 9 | +https://github.com/mongodb/mongo-csharp-driver/blob/master/Release%20Notes/Release%20Notes%20v1.6.1.md |
| 10 | + |
| 11 | +File by file change logs are available at: |
| 12 | + |
| 13 | +https://github.com/mongodb/mongo-csharp-driver/blob/master/Release%20Notes/Change%20Log%20v1.6.1-Bson.txt |
| 14 | +https://github.com/mongodb/mongo-csharp-driver/blob/master/Release%20Notes/Change%20Log%20v1.6.1-Driver.txt |
| 15 | + |
| 16 | +The full list of JIRA issues resolved in this release is available at: |
| 17 | + |
| 18 | +https://jira.mongodb.org/secure/IssueNavigator.jspa?mode=hide&requestId=12609 |
| 19 | + |
| 20 | +Changes to ReadPreference |
| 21 | +------------------------- |
| 22 | + |
| 23 | +The implementation of ReadPreference has been changed to more accurately follow the ReadPreference spec: |
| 24 | + |
| 25 | +http://docs.mongodb.org/manual/applications/replication/#read-preference |
| 26 | + |
| 27 | +The changes are: |
| 28 | + |
| 29 | +- SecondaryPreferred only uses the Primary if no secondaries are available (regardless of latency) |
| 30 | +- SecondayAcceptableLatency is now configurable |
| 31 | +- when sending queries to mongos: |
| 32 | + - ReadPreference.Primary is encoded setting the SlaveOk bit on the wire protocol to 0 |
| 33 | + - ReadPreference.SecondaryPreferred (without tags) is encoded setting the SlaveOk bit on the wire protocol to 1 |
| 34 | + - all other ReadPreferences are encoded using $readPreference on the wire |
| 35 | + - $query is now encoded before $readPreference as required by mongos |
| 36 | +- commands now correctly use the collection settings (they were using the database settings) |
| 37 | + |
| 38 | +Sending commands to secondaries |
| 39 | +------------------------------- |
| 40 | + |
| 41 | +Only a limited set of commands are now allowed to be sent to secondaries. All other commands |
| 42 | +will be sent to the primary regardless of the ReadPreference you specify. The commands |
| 43 | +that can be sent to secondaries are: |
| 44 | + |
| 45 | +- aggregate |
| 46 | +- collStats |
| 47 | +- count |
| 48 | +- dbStats |
| 49 | +- distinct |
| 50 | +- geoNear |
| 51 | +- geoSearch |
| 52 | +- geoWalk |
| 53 | +- group |
| 54 | +- mapReduce (but *only* if using Inline results) |
| 55 | + |
| 56 | +The corresponding helper methods in the C# driver are: |
| 57 | + |
| 58 | +- MongoCollection.Aggregate |
| 59 | +- MongoCollection.GetStats |
| 60 | +- MongoCollection.Count, MongoCursor.Count and MongoCursor.Size |
| 61 | +- MongoDatabase.GetStats |
| 62 | +- MongoCollection.Distinct |
| 63 | +- MongoCollection.GeoNear and MongoCollection.GeoNearAs |
| 64 | +- MongoCollection.GeoHaystackSearch and MongoCollection.GeoHaystackSearchAs |
| 65 | +- MongoCollection.Group |
| 66 | +- MongoCollection.MapReduce (with MapReduceOutputMode.Inline) |
| 67 | + |
| 68 | +There is no helper method (yet) for the geoWalk command. |
0 commit comments