For information on the logic behind the advanced routing and the design for the solution see our series of blog posts.
By default the extensions will not automatically enable the use of the advanced routing in sharded environments. Users must enable the specific type of routing they want to use.
To enable '''targeted''' mode simply set either the system property '''mongodb.shard.connection.mode''' or the environment variable '''MONGODB_SHARDING_MODE''' to '''targeted'''. The comparison is case-insensitive and any other value will revert the connection to the '''default''' mode.
Future versions of the driver and extensions will move the setting to the normal configuration class and also enable additional modes.
The advanced routing capability is provided via the driver's extensions jar available to license holders. Please contact Allanbank Consulting, Inc. for information on licensing the driver and obtaining the extensions jar.