Ana Sayfa / MongoDB

MongoDB

MongoDB Authorization Model

Authorization is the basically verifies user privileges. MongoDB support different kind of authorization models. 1. Role base access control Role are group of privileges, actions over resources. That are gain …

Devamını Oku..

Mongo as a Replica Set

Mongodb as a Replica Set We would be creating mongodb as a replica set having 3 instances. One instance would be primary and the other 2 instances would be secondary. …

Devamını Oku..

MongoDB Replication

Basic configuration with three nodes The replica set is a group of mongod instances that maintain the same data set. This example shows how to configure a replica set with …

Devamını Oku..

Mongo as Shards

Sharding Environment Setupa Sharding Group Members : For sharding there are three players. Config ServerReplica SetsMongos For a mongo shard we need to setup the above three servers. Config Server …

Devamını Oku..

MongoDB Python Driver

ParameterDetailhostXOptional. You can specify as many hosts as necessary. You would specify multiple hosts, for example,for connections to replica sets.portXOptional. The default value is :27017 if not specified.databaseOptional. The name …

Devamını Oku..

MongoDB Java Driver

Fetch Collection data with condition To get data from testcollection collection in testdb database where name=dev import org.bson.Document; import com.mongodb.BasicDBObject; import com.mongodb.MongoClient; import com.mongodb.ServerAddress; import com.mongodb.client.MongoCollection; import com.mongodb.client.MongoCursor; import com.mongodb.client.MongoDatabase; …

Devamını Oku..