Mongodb vs mysql

Source: Internet
Author: User

MongoDB is a distributed file storage-based database. Written in C ++. It is designed to provide scalable, high-performance data storage solutions for WEB applications.
It features high performance, ease of deployment, and ease of use, making it easy to store data. Features:
* It is designed for set storage and is easy to store object-type data.
* Free mode.
* Supports dynamic query.
* Full indexes are supported, including internal objects.
* Query is supported.
* Supports replication and fault recovery.
* Use efficient binary data storage, including large objects (such as videos ).
* Automatic fragment processing to support cloud computing-level scalability
* Supports RUBY, PYTHON, JAVA, C ++, PHP, and other languages.
* The file storage format is BSON (a json extension)
* Accessible through the network
 
Usage principle:
The so-called "Collenction-Oriented" means that data is stored in a data set by groups and is called a set ). Each set has a unique identification name in the database and can contain an infinite number of documents. The concept of a set is similar to that of a table in a relational database service (RDBMS). The difference is that it does not need to define any schema ).
Schema-free means that we do not need to know any schema definitions for the files stored in the mongodb database. If necessary, you can store files of different structures in the same database.
The document stored in the set is saved as a key-value pair. Key is used to uniquely identify a document, which is a string type, and the value can be a variety of complex file types. We call this storage form BSON (Binary Serialized dOcument Format ).
MongoDb cannot completely replace relational databases such as MySQL. MongoDB is mainly used for large websites. Because of the discard relationship constraints, it can improve server execution efficiency, avoid the pressure on the database due to the complexity of the relationship.
Using MongoDB will eat more hard disks, because every piece of data should try not to contact other collections (equivalent to mysql tables ). Hard Disks are currently so cheap that they can be used more easily.
Using mongoDB will allow programmers to work more on handling relationships.
The flexibility of using mongo is very strong, because you can use mongo: command to define a query, so that the database can be customized by programmers.
 
 
Very easy to install.
PHP module available.
Very easy replication, including master-master support. In testing this caught up with our live DB very quickly and stayed in sync without difficulty.
Automatically sharding being developed.
Good documentation.

Author: "tongxiaoming520"
 

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.