Barron,

The score is indeed in the KeyData parameter when running a mapred job with
a Search query as input.  In Erlang the KeyData variable would hold a value
something like `{struct, [{score, [1.0]}, {p, [4,16]}, ...]}`.  Taking a
look at the Java client it seems the functionality doesn't currently exist
but a PR is in the works [1].  If I feel ambitious after dinner perhaps I'll
see if I can get it working.

-Ryan

[1]: https://github.com/basho/riak-java-client/pull/32

On Wed, Aug 3, 2011 at 1:55 PM, Barron Logan <blo...@sharecare.com> wrote:

> hello,
>
> we are using riak search in our project via the riak-java client.
>
> using mapreduce over search; we are getting back bucket-key pairs but need
> to get the search-related scores for each returned object as well.
>
> we believe that the score may be in KeyData parameter but are unsure of how
> to retrieve it?
>
> can someone give an example of how to write a custom map function (js?) to
> retrieve the score, or give some additional guidance please?
>
> advTHANKSance,
>
> -barron
> _______________________________________________
> riak-users mailing list
> riak-users@lists.basho.com
> http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
>
_______________________________________________
riak-users mailing list
riak-users@lists.basho.com
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com

Reply via email to