The MongoDB C# Driver is the 10gen-supported C# / .NET driver for MongoDB.
4
votes
0answers
254 views
MongoDB and Multiple C# Client Threads
I have a single primary instance of a MongoDB to connect to. I am using the C# driver (latest revision) to connect and utilise MongoDB.
My client application is multi-threaded whereby processes will ...
1
vote
0answers
66 views
MongoDB MongoCollection<BsonDocument>.AsQueryable issues
Why does the below code fail at runtime?
MongoCollection<BsonDocument> tempCollection = DBHelper.GetInstance().TempCollection();
IList<BsonDocument> documents = (from d in ...
1
vote
0answers
27 views
How to get MongoCursorEnumerator<T> with latest version C# (1.8.2+) driver?
Having some issues with code which used to work pre-1.8.2 version of C# MongoDB Driver:
With previous releases of the driver, I could do something like:
private MongoCursorEnumerator<T> ...
1
vote
0answers
115 views
mongodb 'count' with query is very slow
everyone,im use a mongodb 2.4.6 version and in windows 2008 64-bit.
i have a collection that have two million records and need to search and paging in client.
...
1
vote
0answers
132 views
MongoDB complex query for matching elements in array and performance
Say I have following data structure:
{
"_id" : LUUID("d14c526e-34ba-4c41-9bb0-3bc32d9de106"),
"Address" : {
"Street" : "Winner street",
"HouseNo" : "776",
"PostalCode" : 9619,
"City" ...
1
vote
0answers
71 views
IDictonary<string,object> object has multiple objects, how to seperate?
I'm currently about to develop a website with asp.net mvc4 and mongodb as database. As the Microsoft Membership Provider does only support SQL-DB's, I've to use another Membership Provider. I decided ...
1
vote
0answers
55 views
Iterating MongoDB cursor blocks forever
I'm using the MongoDB C# driver 1.8.1.20 with Mongo 2.4.3. I use the following infinite loop to poll new messages from a capped collection and process them as they come (with a tailable cursor and ...
1
vote
0answers
43 views
MongoDb C# normal property to versioned property automatically
I have this implementation of versioned property
public class VersionedProperty<T>: Dictionary<int, T>, IParentEntityTracker //where T:IComparable<T>
{
[BsonIgnore]
public ...
1
vote
0answers
162 views
Integrating Autofac and MongoDB C# driver
.NET 4.0 latest autofac version and latest C# driver
We are in the process of integrating the Autofac DI container into our MongoDB app and things have been going swimmingly with one exception which ...
1
vote
0answers
130 views
Connection to remote host MongoDB breaks after a certain number of inserts to the collection
I have my Mongo DB v2.1.2 hosted on remote server. After inserting 58070 records i am getting the following message exception more often
Message = "A transport-level error has occurred when sending ...
1
vote
0answers
79 views
How to duplicate/clone a database in MongoDB with C#
At some events, I want to call a function, that should make a copy of the database and save it as a new MongoDB database with it's name as current Date time.
I just need the C# syntax to ...
1
vote
0answers
325 views
MongoDB C# Socket Exceptions in IIS 7.0 Web Garden (Ex: Only one usage of each socket address (protocol/network address/port) is normally permitted)
I have an ASP MVC app using the 10gen Mongo C# driver (github) to connect to a database server on a specific port. I have this deployed in an IIS 7.0 web garden with 3 worker processes. Every few ...
1
vote
0answers
702 views
C# Mongodb get cursor count
I am trying to find out if a document exists in a collection using the code below. Whenever the query doesn't find any documents I get a StackOverflowException. What am I doing wrong with this?
...
0
votes
0answers
15 views
How remove empty values from the top of the Sort MongoDb
I have these objects:
A: Description: "A"
B: Description: "B"
C: Description: ""
When I use Mongodb sort for the field Description I get the following sort order:
C: Description: ""
A: ...
0
votes
0answers
9 views
get partial GridFS files list when MongoDB shard is down
i'll start saying my only knowledge about shards is from MongoDB Sharding manual (intro, concept, arch, tutorials.. read it all).
"I know Kung Fu"
now, i implemented it all, with 3 config servers, ...