PMXBOT Log file Viewer

Help | Karma | Search:

#mongodb logs for Sunday the 19th of July, 2015

(Back to #mongodb overview) (Back to channel listing) (Animate logs)
[00:23:42] <n3vtelen_> how do I extract a dictionary?
[00:23:56] <n3vtelen_> like this: "comments": [...]
[00:24:48] <n3vtelen_> db.post.find({comments: $all}) ?
[00:40:39] <n3vtelen_> I have this collection http://dpaste.com/181JMX6
[00:40:49] <n3vtelen_> how do I remove duplicate comments?
[00:49:41] <n3vtelen_> is there anyone out there?
[00:54:50] <dandaman> so I've never really worked with a nosql database so my knowledge is a bit limited. I'm building a chat application; would mongodb be the best bet for a simple application or is there another avenue i should be looking into?
[00:55:44] <dandaman> it's for a startup so I'm looking into nosql since the db structure might change a lot
[01:00:25] <StephenLynx> yeah, it would work just fine
[01:04:45] <n3vtelen_> StephenLynx: could you help me?
[01:04:55] <n3vtelen_> StephenLynx: I really stuck at that
[01:07:01] <StephenLynx> wat what
[01:07:39] <n3vtelen_> StephenLynx: http://dpaste.com/181JMX6
[01:08:04] <StephenLynx> my connection is total ass, so I might just look like I am ignoring you, when I am in fact cursing at my connection
[01:08:18] <StephenLynx> what about that
[01:08:28] <n3vtelen_> I want to remove the duplicate elements from comments?
[01:08:40] <StephenLynx> hm
[01:09:06] <StephenLynx> let me think about that
[01:09:24] <n3vtelen_> StephenLynx: did you see the collection?
[01:09:44] <StephenLynx> yes
[01:14:35] <n3vtelen_> StephenLynx: what do you think?
[01:15:15] <StephenLynx> is that a single-time operation?
[01:15:31] <StephenLynx> if so I would read all documents, fix the arrays and update them back on a bulk write.
[01:15:51] <n3vtelen_> I'm a novice
[01:16:02] <n3vtelen_> how do I fix it?
[01:16:18] <StephenLynx> with a script that reads every document, fix the array and update it back.
[01:16:28] <StephenLynx> if that is a single time operation.
[01:16:46] <StephenLynx> that is the easiest way.
[01:17:28] <n3vtelen_> it needs JS ?
[01:17:56] <StephenLynx> no, you can use whatever language you want.
[01:18:03] <StephenLynx> as long as it have a driver.
[11:53:27] <n3vtelen_> why is mongodb channel not active?
[11:58:04] <dimon222> its active, just 7:50 AM bro
[11:58:38] <dimon222> oh he left
[12:56:18] <Siamaster> Is there a way to make a DBObject of an object with Morphia?
[12:57:25] <Siamaster> I want to push to an array with the sort argument, which stops me from using morphia
[12:57:54] <Siamaster> so I have to use the mongodriver
[12:58:15] <Siamaster> mongo().getCollection(MyClass.class).update(query, update)
[12:59:02] <Siamaster> So I wonder if there is way to convert MyColElement to a DBObject
[13:00:36] <StephenLynx> you might want to ask on a place about morphia.
[13:00:43] <StephenLynx> most people here have no idea what that is.
[15:53:41] <daslicht> I am trying to upload files and save them into gridfs while using meteor
[15:54:00] <daslicht> I used busboy to handle the multipart file upload
[15:54:00] <StephenLynx> what is meteor?
[15:54:21] <daslicht> I can now upload files and find them in teh servers temp folder
[15:54:29] <daslicht> now I like to save those files into gridfs
[15:54:31] <daslicht> https://gist.github.com/daslicht/cc0078025503076727c0
[15:54:41] <daslicht> what I am missing there?
[15:54:53] <daslicht> StephenLynx: https://www.meteor.com
[15:55:01] <StephenLynx> gs.writeFile(path, function wroteFile(error) {
[15:55:11] <StephenLynx> what is in that link?
[15:55:17] <daslicht> tahts meteor
[15:55:19] <daslicht> :)
[15:55:25] <StephenLynx> good for you.
[15:55:32] <daslicht> not only for me
[15:55:39] <daslicht> thank you i will try that
[15:55:45] <StephenLynx> Images.insert
[15:55:53] <StephenLynx> you don't handle gridfs like a regular collection.
[15:56:14] <daslicht> i see , i just started with it
[15:57:12] <daslicht> is that the correct place to read on it:
[15:57:13] <daslicht> http://docs.mongodb.org/manual/core/gridfs/
[15:57:13] <daslicht> ?
[15:57:22] <daslicht> I only saw chunks and files there
[15:57:28] <StephenLynx> I would use the documentation of the driver.
[15:57:33] <daslicht> and files is only for metadata ?
[15:57:40] <StephenLynx> http://mongodb.github.io/node-mongodb-native/2.0/api/GridStore.html
[15:57:54] <StephenLynx> fs.files is an auto-handled collection for metadata, yes.
[15:58:03] <StephenLynx> but you can use another name for it if you wish.
[15:58:52] <daslicht> I am using this one here:
[15:58:52] <daslicht> https://github.com/CollectionFS/Meteor-CollectionFS
[15:59:31] <StephenLynx> "Meteor-CollectionFS"
[15:59:36] <StephenLynx> crap.
[15:59:49] <daslicht> why?
[15:59:49] <StephenLynx> Imo it will give you nothing but trouble.
[15:59:58] <daslicht> yeah looks like
[16:00:04] <StephenLynx> because it doesn't provide any features while changing the workflow
[16:00:11] <daslicht> i used it since it interegrates with meteor
[16:00:16] <daslicht> i see
[16:00:19] <daslicht> what a mess
[16:00:21] <StephenLynx> what is meteor and why are you using?
[16:00:37] <daslicht> meteoe is a javascript framework for building realtime reactive webapps
[16:00:42] <daslicht> its quite popular...
[16:00:51] <StephenLynx> sounds like garbage.
[16:01:01] <StephenLynx> bunch of meaningless buzzowords.
[16:01:09] <StephenLynx> PHP is popular too.
[16:01:20] <StephenLynx> so is windows.
[16:01:22] <daslicht> I use PHP eitehr
[16:01:27] <StephenLynx> top kek
[16:01:38] <daslicht> anyways
[17:03:45] <dbclk> does mongo cluster heartbeat uses TCP or UDP?
[17:08:09] <cheeser> TCP
[21:09:28] <amitprakash> hi, while syncing up new replicas, why does mongo build indexes one by one as opposed to in parallel?
[21:28:14] <amitprakash> is this channel always quiet?
[21:28:28] <StephenLynx> no
[21:28:53] <amitprakash> StephenLynx, well I've asked various questions at various times of the day to be met with silence :(
[21:30:26] <StephenLynx> no one else knew the answer or weren't interested in replying.
[21:30:44] <StephenLynx> for one, I have absolutely no idea how to work with replicas.
[21:31:42] <amitprakash> StephenLynx, that is surprising! You guys rely purely on sharding? No separation of reads and writes?
[21:33:00] <StephenLynx> I never deployed a big system with mongo.
[21:33:08] <StephenLynx> I have just been working with it for a year now.
[21:33:17] <amitprakash> oh okay :)
[21:33:47] <amitprakash> I've been using it for ~3 years now and its still incredibly hard to manage at scale
[21:33:54] <amitprakash> easier than relational, but still hard
[21:35:15] <amitprakash> StephenLynx, for one thing, it takes me roughly 2 days to restore a replica
[21:35:24] <amitprakash> and mms snapshots suck
[21:35:34] <StephenLynx> daium
[21:36:29] <amitprakash> almost all of this time is indexing .. 3hrs per index :(
[21:36:57] <amitprakash> wt improves on this significantly, but querying is significantly slower on WT for COLLSCANS
[23:57:28] <PatOlsson> Hey, I'm trying to do an online minesweeper game, using the MEAN stack, and I'm stuck with how to structure the DB. I want a matrix of mine objects, like this:( http://pastebin.com/bEMTASZX ), and now I'm using subdocuments (see later part of previous pastebin). Unfortunately I cannot find the Mine object by id, is this because of how I added the Board to the DB? (http://pastebin.com/0RYfhHfR). Should I instead somehow add each