josiah-wolf-oberholtzer / discograph

Social Graphing for the Discogs Database
MIT License
74 stars 11 forks source link

Investigate migrating DB to PostgreSQL. #37

Closed josiah-wolf-oberholtzer closed 8 years ago

josiah-wolf-oberholtzer commented 9 years ago

PostgreSQL supports full-text search and BSON fields, making it able to mimic MongoDB nested structures.

If the memory requirements are not prohibitive, PostgreSQL could replace the current MongoDB/Sqlite frankenstein.

Soupala commented 9 years ago

I'm very interested in the answer. @clemsos and I have been contemplating how to deal with large databases while also providing real time, collaborative editing and navigation of these types of graphs. We have some experiments going using CytoscapeJS. Currently we are working in Meteor and trying to figure out if there is some way to work with MongoDB. I'm thinking maybe the ticket is real graph support in Meteor like Neo4j or something flexible like ArrangoDB, or OrientDB.

josiah-wolf-oberholtzer commented 9 years ago

Hmm. I'll take a look at those. My main concern at the moment is memory footprint. The containers I can afford to deploy on have 1GB of memory, which is why I can't use MongoDB - it wants to keep all of its indexes in memory, and (as of last month) had an issue where rebuilding indexes would ignore the memory constraints in your mongo.conf.

So, I moved to Sqlite, which has been blazingly fast, but required dropping most of the extra data I have in my MongoDB version.

Soupala commented 9 years ago

You mentioned memory footprint... I thought of DEX, or what is now called Sparcity, http://www.sparsity-technologies.com/

[ {name : "Mica Cardillo"} , {phone : "541.840.7245"}, {love: ['Dahlia', 'Oliver', 'Rachel']} ]

On Thu, Oct 1, 2015 at 9:03 AM, Josiah Wolf Oberholtzer < notifications@github.com> wrote:

Hmm. I'll take a look at those. My main concern at the moment is memory footprint. The containers I can afford to deploy on have 1GB of memory, which is why I can't use MongoDB - it wants to keep all of its indexes in memory, and (as of last month) had an issue where rebuilding indexes would ignore the memory constraints in your mongo.conf.

So, I moved to Sqlite, which has been blazingly fast, but required dropping most of the extra data I have in my MongoDB version.

— Reply to this email directly or view it on GitHub https://github.com/josiah-wolf-oberholtzer/discograph/issues/37#issuecomment-144772707 .

josiah-wolf-oberholtzer commented 9 years ago

Interesting, but it looks like Sparcity is encumbered with a restrictive license.

I'm pretty sure I can make do with just Sqlite, or with a development-machine-local Postgres DB that just dumps to Sqlite.

josiah-wolf-oberholtzer commented 8 years ago

Disco/graph has now happily migrated to using PostgreSQL.