Which best suits my needs: MongoDB, CouchDB or MySQL. Specific criteria

Our website needs a content management system. For example, administrators want to create advertising pages on the fly. They will provide text and images for the page and the URLs on which the page should be. For this we need a data warehouse. The criteria for the data warehouse are simple and defined below. I am not familiar with CouchDB or MongoDB, but I think they may be better suited for this than MySQL, but I am looking for someone who has more knowledge of MongoDB and CouchDB to listen to.

On a scale of 1 to 10, how would you rate MongoDB, CouchDB, and MySQL for the following:

  • Java client
  • Web click tracking
  • CMS as a system
  • Save downloaded files
  • Easy to install fault tolerance
  • Support
  • Documentation

What would you choose in these circumstances?

+7
mysql mongodb couchdb content-management-system
source share
5 answers

Each of them is suitable for different occasions. But in small places traffic mysql / postgresql is better.

Java client: all of them have clients

Web click tracking: mongo and cassandra are more suitable for this highly recorded situation.

Save uploaded files: mongo with gridfs is suitable. Cassandra can store up to 2 GB per column divided by 1 MB. mysql is not suitable. saving only the file location and saving the file in the file system is recommended for cassandra and mysql.

Easy to switch to another resource: cassandra - best, mongo second

Support: everyone has good support, mysql has the largest community, mongo is the second

Documentation: 1st mysql, 2nd mongo

I prefer MongoDB for analytics (web clicks, counters, logs) (you need a 64-bit system) and mysql or postgresql for the main data. on companies that use the mongo page on the mongo website, you can see that most of them use mongo for analytics. mongo may be suitable for master data after version 1.8. The problem with cassandra is poor query capabilities (not suitable for cms). and the problem with mysql is not so easily scalable, and HA like cassandra and mongo, as well as mysql, are slower, especially when writing. I do not recommend couchdb, it is the slowest.

My best

Serdar Irmak

+6
source share

Here are some quick answers based on my experience with Mongo.

Java client

Not sure, but it exists and is well maintained. Lots of documents , even a few POJO wrappers to simplify.

Web click tracking

8 or 9. It is very easy to make both inserts and updates thanks to the “fire and forget”. MongoDB has built-in tools for comparing data and simple tools for exporting data to SQL for analysis (if Mongo is not good enough).

CMS as a system

8 or 9. Easily store the contents of an entire web page. It’s very easy to “hook” on extra columns. This is really a Mongolian "bread and butter".

Save downloaded files

There is a learning curve here, but Mongo has a GridFS system designed specifically for storing and maintaining binary data.

Easy fault tolerance setup

Start the main server: ./mongo --bindip 1.2.3.4 --dbpath /my/data/files --master Run your slave device: ./mongo --bindip 1.2.3.5 --dbpath /my/data/files --slave --source 1.2.3.4

Support

10gen has a mailing list: http://groups.google.com/group/mongodb-user . They also received payment.

Their response time is usually somewhere between excellent and amazing.

Documentation

Medium. All this is, but it is still a little discordant. Shake it one last time before a lot of new developments.

+5
source share

My CouchDB trick:

Java client: great, use ektorp, which is a fairly simple and complete mapping of objects. In any case, all the APIs are just Json over HTTP, so all this is easy.

Web click tracking: Perhaps redis is the best tool for this. CouchDB is not the best option here.

A CMS-like system: it's great, as you can easily combine patterns, dynamic forms, data, etc. and match them using representations.

Save uploaded files: Any document in couchdb can have severe attachments to make it natural.

Easy to set up fault tolerance: Master / master replication ensures that you will always read, the database will never be corrupted, so in the event of a failure it is only a matter of the couch starting again and it will go where it will stop (minimum downtime) and replication will catch changes.

Support: availability of a mailing list and paid support.

Documentation: Use the open book http://guide.couchdb.org and the wiki.

+2
source share

I think there are many other posts related to this topic. However, I will be calling since I switched from mysql to mongodb as well. It is fast, very fast, but that does not mean that it is perfect. My advice, use what is convenient for you. If you need more time to refactor to match a mongo or couch, then stick with mysql if that's what you're familiar with. If this is what you want as a skill set, then you should definitely learn mongodb or couchdb.

For me, I went with mongodb for several reasons, storing files through gridfs and geolocation. Yes, I could use mysql, but I wanted to see what all this fuss was about. I must say, I am impressed, and I still have ways to go before I can say that I like mangoes.

With what you pointed out, I can tell you that mongo will fit most of your needs.

0
source share

I don’t see anything here like "you need to process millions of req / s", which indicates that your own version will be better than using something from a shelf, such as Drupal.

0
source share

All Articles