DEV Community

Igor Rudel
Igor Rudel

Posted on

MongoDB Sharding

O MongoDB possui o recurso de Sharding (Fragmentação)!

É um método que o Mongo permite habilitar em coleções, preferencialmente as gigantes (muitos documentos), distribuindo os documentos da coleção em diferentes máquinas e proporcionando maior performance em operações que venham a ser feitas nas coleções fragmentadas.

O Mongo divide os documentos de uma coleção por uma chave de fragmento, que pode ser um ou vários campos dos documentos.

Link do GitHub utilizando Spring Boot e Sharding: https://github.com/oigorrudel/mongodb-shard-example

Fontes:
https://www.mongodb.com/pt-br/docs/manual/sharding/

https://docs.spring.io/spring-data/mongodb/reference/mongodb/sharding.html

Top comments (0)

Image of Datadog

The Essential Toolkit for Front-end Developers

Take a user-centric approach to front-end monitoring that evolves alongside increasingly complex frameworks and single-page applications.

Get The Kit

👋 Kindness is contagious

Dive into an ocean of knowledge with this thought-provoking post, revered deeply within the supportive DEV Community. Developers of all levels are welcome to join and enhance our collective intelligence.

Saying a simple "thank you" can brighten someone's day. Share your gratitude in the comments below!

On DEV, sharing ideas eases our path and fortifies our community connections. Found this helpful? Sending a quick thanks to the author can be profoundly valued.

Okay