The shell and drivers should detect based on wire version whether or not the server supports the find and getMore commands and then use the appropriate protocol for .find() operations.
The shell should support three values for the --readMode flag:
- compatibility: This is the default if no value is supplied for --readMode. This mode indicates that the shell should use the wire protocol version from the response to an isMaster command in order to determine which read protocol to use. If the server supports find/getMore commands, the shell should use "commands" readMode. Otherwise, the shell should degrade to legacy OP_QUERY/OP_GET_MORE reads.
- legacy: Forces the shell to use legacy OP_QUERY/OP_GET_MORE reads regardless of the wire protocol version.
- commands: Forces the shell to use find/getMore commands regardless of the wire protocol version.
You can also set the shell to use a particular readMode at runtime: