Drivers
14 results found
-
Support TagWithCallSite and TagWith with EF Core Provider
It'd be good to support TagWithCallSite and TagWith so it's easier to figure out where the queries came from. The "tag" could be put in the query option comments so that it can be used when profiling and with otel integrations.
1 vote -
Add support for new pagination feature
Please add support for new pagination features explained here:
https://www.mongodb.com/docs/atlas/atlas-search/paginate-results/1 vote -
.NET 6.0 support for Entity Framework driver
The pre-release version of the EF support in C# driver is only published for .NET 7.0 while the LTS version of .NET is 6.0 and many vendors use (and will use it) for a long time. The roadmap from https://github.com/mongodb/mongo-efcore-provider#limitations–roadmap doesn't mention support for any other .NET versions.
The support of .NET 6.0 would potentially increase adoption and user base.
1 vote -
Support for FilterDefinition as part of Atlas Search/$search
Allow the Search Function to accept a FilterDefinition<T> object and/or a SortDefinition object to do the filtering/sorting as part of the Search routine instead of it being in a unique format only to search.
1 vote -
Asynchronous variant of IIdGenerator
We have use cases where IDs assigned to documents are generated by an external service. Communication with the external service is asynchronous. We have created custom IIdGenerator implementations for this purpose, and they work, but unfortunately the IIdGenerator interface is synchronous only. This exposes the known problems with "sync over async" code.
Obviously we could assign the IDs manually and not rely on using an IIdGenerator, but it would be very convenient to have an async variant of the IIdGenerator interface for this use case.
2 votes -
Create a close method on the MongoClient.
I have run into a situation where threads are not being garbage collected and are causing a serious issue. When we create a database for a specific user, we generate the users’ credentials inside of that database with access only to that database. The problem arises when we need to delete the user and database. The user sometime in the past connected to MongoDB using their credentials which leaves behind an open thread to the MongoDB that is logging into MongoDB once a minute with that users’ credentials. We then come along with our Admin user account and delete the…
2 votes -
SnakeCaseElementNameConvention
Please add support for snake case convention. Snake Case is super popular with API designs.
https://mongodb.github.io/mongo-csharp-driver/2.13/reference/bson/mapping/conventions/
1 vote -
GeoNear support on C# driver
Would be great to have GeoNear support on csharp driver https://docs.mongodb.com/manual/reference/operator/aggregation/geoNear/
1 vote -
BsonIgnoreIfEmpty - Property Attribute
Like BsonIgnoreIfDefault and BsonIgnoreIfNull, we can add BsonIgnoreIfEmpty.
It can be added on IEnumerables (which we basically know they cannot have infinite values since it is inserted to db after all..) and if the IEnumerable is empty, it wont serialize it to the db BUT will know to put default value (an empty list for example) in said property.They will decrease below boilerplate code for IEnumerable<T>:
Serialization:
Field = otherField?.count > 0 ? otherFIeld : null;Deserialization:
otherField = Field ?? new List<T>;Obviously, we can improve this code to also support Dictionary<Tkey, Tvalue>.
3 votes -
Expired Transactions failures should be reported more clearly in the driver error message
Long-running transactions may trigger an aborted transaction, but the cause is not clearly communicated by the driver exception message.
Failed: Command insert failed: Transaction 1 has been aborted..
Unhandled exception. MongoDB.Driver.MongoCommandException: Command insert failed: Transaction 1 has been aborted..To reproduce, set a very low timeout:
replicaset:PRIMARY> db.adminCommand( { setParameter: 1, transactionLifetimeLimitSeconds: 1 } )
Then run a long running transaction from the C# driver.
The cause can be confirmed by checking the MongoDB log for a [abortExpiredTransaction]:
replicaset:PRIMARY> show log global
2020-07-31T03:59:49.196+0000 I COMMAND [abortExpiredTransactions] Aborting transaction with txnNumber 1 on session xxxxxx because it has been running for…
2 votes -
Create MSI package to install .NET MongoDB driver
I manage SQL Server. I would like to request standalone 32 and 64 bit MongoDB .Net Driver in MSI format. We typically do not install Development tools on SQL Server database hosts (no visual studio, no nuget.exe). So downloading the driver using package manager is challenging. If that is not possible, can you provide us how to download and install the driver using Powershell?
1 vote -
Create / Update LabVIEW Driver
There seem to not exist any official LabVIEW Drivers / VIs for MongoDB.
There do exist some LabVIEW VIs for MongoDB that work very well based on a C# DLL:
https://github.com/RBXSystems/mongo-labview-driver/tree/master/CSharp/bin.However those only work with older MongoDB Versions and I can`t get them to work with Atlas and the most recent MongoDB Version 4.2, I guess the DLLs need to be updated (and depending on the changes of the API also some of the VIs)
3 votes -
if drive can deal with DateTime.Date,it will be useful
we offen have this require,we need to compare DateTime field on Date(exclude time),but if use drive compare with DateTime.Date,drive will throw a exception tell us dont support..
db.CheckOns.Find(x => x.RecordTime.Date == new DateTime(2020, 3, 19)).ToList();
//public DateTime RecordTime{get;set}2 votes -
use ConventionPack in aggregate same as find
for example :We want save string value of Enum to database,we set EnumRepresentationConvention Convention.
then we can use it in match. but in aggregate group,it dosent work:public enum Gender { Male,Female}
public class Person
{
public int Age { get; set; }
public Gender Gender { get; set; }
}
[HttpGet("test")]
public object Test()
{
var query=db.database.GetCollection<Person>("persons").Aggregate().Group(x => x.Age,g=>new {
g.Key,
MaleCount=g.Sum(x=>x.Gender==Gender.Male?1:0),
FemaleCount = g.Sum(x => x.Gender == Gender.Female ? 1 : 0),
});
var queryString = query.ToString();
return queryString;
}
//queryString will be: aggregate([{ "$group" : { "id" : "$age", "MaleCount" : { "$sum" : {…2 votes
- Don't see your idea?