use yokozuna or riak_search for {search, ...} MR inputs
use yokozuna or riak_search for {search, ...} MR inputs

There are two ways to use riak_search inputs for MapReduce:
 * specify a {modfun, ...} input ({"module":...,"function":...} in json)
 * specify a {search, ...} input ({"bucket":...,"query":...} in json)

This patch allows yokozuna to power the second type instead of
riak_search. The value of the "bucket" field is used as the name of the
yokozuna index.

This patch does not convert the modfun version, to keep from surprising
users, and to allow an escape hatch for people that need to use both.

If only one of riak_search or yokozuna is enabled, that system is chosen
to power search MR inputs.

If both are enabled, then the riak_kv's appenv 'mapred_search' must also
be defined as either 'riak_search' or 'yokozuna'. If it is not defined,
or it is defined as something else, and error will be returned from the MR.

If neither is enabled, an error is returned from the MR.

The automatic nature of the switch is intended to keep configuration as
minimal as possible: the extra riak_kv setting is only needed if *both*
riak_search and yokozuna are to be used, *and* the user wants to use the
non-modfun forms. If only one search system is enabled, or only modfun
input forms are used, the correct thing just happens.

andytill/riak_kv