-
Type: Question
-
Resolution: Done
-
Priority: Minor - P4
-
None
-
Affects Version/s: 2.4.6
-
Component/s: Aggregation Framework, Internal Client
-
Environment:Linux Ubuntu 12.04 single shard server with 4 nodes in one replicaset 2.4.6
Hello.
In C++ i tried execute aggregation framework like in example with readPreference :
conn->runCommand( "goods", BSON( "aggregate" << "events" << "pipeline" << pipeline<<"$readPreference"<<BSON("mode"<<"secondaryPreferred")), res);
Client connected to monogos with one single shard with four nodes in replicaset. Command always execute on primary node.
I dont understand, how execute framework on secondary node.
Is it possible?
Thank you.