News for hackers. Stuff that matters.
Re:Scaling with MongoDB (or how Urban Airship abandoned it f... by tszming on Wednesday June 22, 2011 @10:22PM (#2686375)
Interesting, so the _id trick mentioned by FooBarWidget is not the real reason for the speedup?
Re:Scaling with MongoDB (or how Urban Airship abandoned it f... by FooBarWidget on Thursday June 23, 2011 @04:03AM (#2687097)
It is. I was using a totally random string key, not the default ObjectID.
Re:Scaling with MongoDB (or how Urban Airship abandoned it f... by tszming on Thursday June 23, 2011 @09:58AM (#2687849)
So if you stick with the default _id, the claim of "Your indexes must fit in memory" is no longer valid?
Re:Scaling with MongoDB (or how Urban Airship abandoned it f... by FooBarWidget on Thursday June 23, 2011 @10:15AM (#2687918)
That totally depends on your workload. In my case my working set happens to be mostly equal to the most recently inserted data. If you have to regularly access lots of random documents with no locality whatsoever then your working set is very large and should fit in memory.

By sticking with the default _id, with my workload my _id index doesn't have to fit into memory. I can't actually use the default _id for various reasons but that's a whole different discussion.

Re:Scaling with MongoDB (or how Urban Airship abandoned it f... by tszming on Thursday June 23, 2011 @10:41PM (#2690743)
Useful information, thanks!