diff --git a/datastore-mongodb/src/main/java/org/opencb/datastore/mongodb/MongoDataStoreManager.java b/datastore-mongodb/src/main/java/org/opencb/datastore/mongodb/MongoDataStoreManager.java
index <HASH>..<HASH> 100644
--- a/datastore-mongodb/src/main/java/org/opencb/datastore/mongodb/MongoDataStoreManager.java
+++ b/datastore-mongodb/src/main/java/org/opencb/datastore/mongodb/MongoDataStoreManager.java
@@ -113,7 +113,8 @@ public class MongoDataStoreManager {
                 MongoClientOptions mongoClientOptions;
                 MongoClientOptions.Builder builder = new MongoClientOptions.Builder()
                         .connectionsPerHost(mongoDBConfiguration.getInt("connectionsPerHost", 100))
-                        .connectTimeout(mongoDBConfiguration.getInt("connectTimeout", 10000));
+                        .connectTimeout(mongoDBConfiguration.getInt("connectTimeout", 10000))
+                        .readPreference(ReadPreference.valueOf(mongoDBConfiguration.getString("readPreference", "primary")));
 
                 if (mongoDBConfiguration.getString("replicaSet") != null && !mongoDBConfiguration.getString("replicaSet").isEmpty()) {
                     System.out.println("Setting replicaSet to " + mongoDBConfiguration.getString("replicaSet"));
mongodb: replicaSet is passed to MongoClientOptions