Introduction to the official C# driver from 10gen



10gen is happy to announce support for the official C# driver for MongoDB. Several preview releases have already been made available, and the latest, Version 0.11, was released January 25, 2011. Version 1.0 has just been released and includes support for the new features in MongoDB 1.8.

The official C# driver is designed to be fast and efficient, is fully supported by 10gen, and will have full support for new MongoDB features as new server versions are released. Version 1.0 is compatible with Visual Studio 2008 and 2010 and .NET 3.5. The driver is well suited for use in high load environments as the main classes are all thread safe and connections are efficiently and automatically managed by a connection pool. The driver can connect directly to a particular server, or can connect to a replica set and automatically find the current primary (as well as automatically rollover to a new primary as needed). SafeMode can be enabled to automatically call getLastError after every update operation to check for errors. Full serialization support for C# classes is provided to make integrating your domain model classes with MongoDB easy (including keeping your domain classes persistent ignorant if desired). The serialization support provides several ways for you to customize serialization of particular classes or data types should your classes require special handling. Interoperability with JavaScript and other languages is enhanced by the included JSON reader and writer. GridFS support is provided to deal with large documents (or files) that are too big to store as a single BSON document.

More information about the official C# driver is available at:

A webinar, “Introduction to the New Official C# Driver Developed by 10gen”, is available at:

We are excited to be officially supporting the .NET community with this new driver.

-Robert Stam