[01:19:11] <bros> rl0:PRIMARY> var before = new Date(); var docs = db.items.find( { account_id: ObjectId('561bffa148deeaf021a0ef5d') }).batchSize(1000).toArray(); var after = new Date(); after - before;
[02:39:29] <idioglossia> Is MongoClient.connect() considered expensive? Should I try and preserve the connection throughout an app by passing it around?
[02:39:38] <idioglossia> Or should I reconnect for any disjointed queries
[02:39:46] <idioglossia> as opposed to connecting once at the start of the app
[15:41:13] <Sagar> { "_id": 1, "data": { "new": { "other": 1 } } } i have this mongodb data, i want to increment it's value DB::connection("mongodb")->collection("developers")->where("uid", $id)->increment("data['new']['other']", 1); but nothing happens, is my query right? Using Laravel 5 on php 7
[16:34:01] <idioglossia> Should each module in node have its own connection to mongo?
[16:34:57] <idioglossia> The connection isn't established until the callback succeeds, so I could either block until the callback indicates the connection was successful, or I could just create a new connection every time I need to do a new set of queries
[16:35:32] <idioglossia> hmm actually I could just start the node app in the callback of the connection. That way it's established the whole time