Caracteristicas de MongoDB
Implementing Collections in MongoDB:
• Collections are flexible, analogous to boxes with labels, storing similar items.
• They don't enforce strict definitions like tables in relational databases.
• You can mix different items in a collection, but it's better to group similar items.
• MongoDB creates collections on demand when saving documents that reference them.
• Multiple collections in MongoDB have no significant performance impact.
Understanding Databases:
• MongoDB databases are collections of collections.
• Databases are created on demand, and applications can create databases for customers.
• Organizing databases requires thoughtful planning for efficient data management.
Reviewing the Feature List:
• MongoDB offers various features for a powerful and flexible database management system.
• Features include BSON for document-oriented storage, dynamic queries, indexing, geospatial
indexing, query profiling, in-place updates, GridFS for binary data, data replication, auto sharding, and
map/reduce functions.
Using Document-Orientated Storage (BSON):
• MongoDB uses BSON for document storage in binary format.
• BSON provides better query and indexing performance compared to JSON.
• It enables quick conversion to native data formats of programming languages.
Supporting Dynamic Queries:
• MongoDB supports dynamic queries without predefining them.
• It allows easy querying with the parts of documents to match against.
• Advanced features like map and reduce functions are available for complex queries.
Indexing Your Documents:
• MongoDB extensively supports indexing documents.
• All documents are indexed on the _id key for uniqueness.
• Additional indexes can be created on other keys, embedded documents, and composite keys.
Leveraging Geospatial Indexes:
• MongoDB offers specialized geospatial indexing for location-based data.
• It allows queries based on geographic coordinates, useful for location-based applications.
Profiling Queries:
• MongoDB provides a query profiler to identify performance bottlenecks.
• Helps optimize queries by adding appropriate indexes or improvements.
Updating Information In-Place:
• MongoDB updates data in-place, improving performance with lazy writes.
• It does not guarantee data safety compared to traditional RDBMS databases.
Storing Binary Data:
• GridFS in MongoDB stores binary data, breaking it into chunks.
• Efficiently handles large files and allows easy retrieval.
Replicating Data:
• MongoDB uses master-slave replication for data safety.
• One active master database replicates data to a slave database.
Implementing Auto Sharding:
• Auto sharding enables scalable deployments by automatically splitting and recombining data.
• It simplifies management and improves scalability for large-scale databases.
Using Map and Reduce Functions:
• MongoDB supports map and reduce functions for advanced data analysis.
• Written in JavaScript, they run on the server, providing a flexible way to query and process data.