skip to Main Content

Mongodb – Fake IMongoQueryable with FakeItEasy

I'm developing an API which communicates with MongoDB and I need to create some statistics from one collection. I have the following service: public class BoxService : IBoxService { private readonly IMongoCollection<Box> _boxCollection; public BoxService(IOptions<DbSettings> dbSettings, IMongoClient mongoClient) { var…

VIEW QUESTION

Mongodb – MongoServerError: user is not allowed to do action [find] on [genius-car.service]

I was trying to learn MongoDB CRUD operations along with node express js when i try to go 'http://localhost:5000/service' its throwing the following error : D:Projects_WebDevBackEndserver-genius-car-servicenode_modulesmongodblibcmapconnection.js:207 callback(new error_1.MongoServerError(document)); ^ MongoServerError: user is not allowed to do action [find] on [genius-car.service]…

VIEW QUESTION
Back To Top
Search