[04:26:23] <dvass> so I have a User, Products, Purchases and Apps
[04:26:29] <Boomtime> dvass: go ahead and describe your scenario, be aware that your topic tends to produce highly varied responses depending on the experience of people responding
[04:26:48] <dvass> (or at least this is how I plan on doing it but I haven't really worked with NOSQL before)
[04:26:52] <dvass> so yeah, I have those 4 categories
[04:27:40] <dvass> The basic scenario is that each User can have multiple Apps and each App can have multiple Product and each user can have multiple Purchases
[04:27:48] <dvass> and with traditional SQL I would have just linked the mtogether
[04:27:58] <dvass> so in purchases I'd have User ID and Product ID in each entry
[04:41:20] <Boomtime> finally, in a sql you arrange your schema to be easy to write to, and then write big complicated queries with lots of joins to read - i.e the schema is easy to write, but hard to read
[04:41:49] <Boomtime> in monogdb it's the opposite, you should spend all your time optimizing the schema for read, which makes your data likely to be harder to write
[04:42:50] <Boomtime> data is almost universally read more often than it's written - so it makes sense to be optimized for read, not writing
[04:43:41] <Boomtime> note, i'm talking about the effort required on app developer to implement, mongodb itself is fast at both
[04:47:39] <dvass> Boomtime: Hmm, so the approach I said - is that optimised for write?
[04:47:55] <dvass> Because I would just have to modify one value to change product name
[04:48:01] <dvass> as opposed to go through entire DB to edit it everywhere
[04:48:26] <Boomtime> how often does a product change name?
[04:48:49] <Boomtime> because we you just described is 'optimizing for write'
[04:50:34] <Boomtime> consider the work it takes to display a purchase in your model; you query for the purchase, then query for the product doc (to get the name), then query for the user doc (to get the name of the user presumably)
[04:51:14] <dvass> but how do you maintain consistency throughout the db?
[04:51:29] <Boomtime> you need those relationships - but consider what information you really need most of the time (optimize for read)
[04:52:09] <Boomtime> when you read a purchase: you want the purchase doc to be largely self-sufficient; so embed the product name (along with the product ID)
[04:52:31] <dvass> Boomtime: So I should still have the product ID?
[04:52:47] <Boomtime> this has some interesting benefits; even if you delete the product, old purchases can still display what the item was (partially)
[04:53:20] <dvass> well then why not just have purchases in the Users
[04:53:29] <Boomtime> but this increases the amount of work you need to do to change the product name - you need to find all the purchases and change those too - this is why i asked how often does a product change name
[04:53:57] <Boomtime> but would that be an unbounded array?
[04:54:24] <Boomtime> is there a limit (even if it's thousands) to how many purchases a user can have?
[04:55:21] <Boomtime> your design is greatly influenced by your use case - just like in sql - so the answer to every question is usually predicated on "it depends"
[04:59:05] <Boomtime> learning something new always feels more complex
[04:59:55] <Boomtime> mongodb is a radical departure from sql - you really do need to be immersed in for awhile before it kind of clicks and you throw away what you realize was this bizarre burden that sql was actually imposing
[05:00:32] <Boomtime> of course, everything comes with a cost i suppose - welcome to the learning curve
[05:03:05] <dvass> Boomtime: haha ok well then how would you recommend I make it
[23:18:32] <zamnuts> Over the past few weeks my active MMS monitoring agent will intermittently have connectivity issues for a few minutes every 2-5 hours. This "MMS monitoring agent down" cluster of events happens once every 4 or 5 days. The main error is simply "dial tcp X.X.X.X:443: connection refused" - log snippet for context: http://pastebin.com/1Epz6wAP
[23:19:08] <zamnuts> Any idea what is going on? The servers are not going down, and the MMS agents are not failing over since it is an outbound network connectivity issue.
[23:21:21] <preaction> what does that have to do with mongodb?
[23:22:08] <zamnuts> MMS is mongodb's monitoring tool?
[23:23:11] <preaction> ah, because of course they'd take a known acronym to make it confusing...
[23:23:47] <zamnuts> :) i suppose now-a-days they refer to it as MongoDB "Cloud" but w/e, the agent package is still labeled "mms"
[23:24:32] <preaction> they could've gone with Monmon!
[23:28:31] <joannac> that IP is for the cloud manager servers
[23:28:39] <zamnuts> preaction, "monmon" is installed on my server (firewalled), it regularly sends data to api-agents.mongodb.com hosted cloud servers
[23:28:47] <joannac> the issue is your connectivity to CM servers
[23:29:42] <preaction> connection refused is pretty specific. it's not connection timed out, or connection lost, or no route to host
[23:29:45] <zamnuts> joannac, my local network monitoring doesn't report any outages
[23:30:56] <joannac> zamnuts: you've verified you can connect to that IP and port?