.version(version) // .withLaunchArgument("--quiet", null) // .net(new Net(LOCALHOST, port, Network.localhostIsIPv6())) //
public MongosConfigBuilder version(IFeatureAwareVersion version) { version().set(version); return this; }
@Override public IMongosConfig build() { IFeatureAwareVersion version = version().get(); Net net = net().get(); Timeout timeout = timeout().get(); String configDB = get(CONFIG_DB); String replicaSet = get(RELICA_SET); IMongoCmdOptions cmdOptions=get(CMD_OPTIONS); String pidFile = get(PID_FILE); return new ImmutableMongosConfig(version, net, timeout, cmdOptions, pidFile, configDB, replicaSet, args); }
int mongosPort = 27017; IMongosConfig config = new MongosConfigBuilder() .version(version) .net(new Net(configServerPort, Network.localhostIsIPv6())) .configDB("testDB") .version(version) .net(new Net(mongosPort, Network.localhostIsIPv6())) .configDB(Network.getLocalHost().getHostName() + ":" + configServerPort)