riak_search: custom extractor syntax

Greg Pascale greg at clipboard.com
Tue Jul 19 13:40:37 EDT 2011

I've been debugging through the riak code, and it looks like the
riak_search_js_extract process is not running, so it's not even getting to
the point of executing my JS. Has this feature ever worked?

=ERROR REPORT==== 19-Jul-2011::10:25:24 ===
problem invoking hook riak_search_kv_hook:precommit -> exit:{noproc,



On Mon, Jul 18, 2011 at 6:22 PM, Greg Pascale <greg at clipboard.com> wrote:

> Hi,
> I'm trying to use a custom extractor, but I can't for the life of me seem
> to get the syntax right. Even the simplest thing I can think to try won't
> work.
> I've tried setting the rs_extractfun property as described in the
> documentation - both of these methods
>    - {jsanon, {Bucket, Key}}, where Bucket and Key name a Riak object that
>    contains the source of a Javascript function to call for extraction.
>    - {jsanon, Source}, where Source is the source of a Javascript function
>    to call for extraction.
> > Client:set_bucket(<<"extractTest">>, [{rs_extractfun, {jsanon,
> <<"function(){return{'name':'greg', 'login':'gpascale'};}">>}}]).
> > Client:set_bucket(<<"extractTest">>, [{rs_extractfun, {jsanon,
> {<<"extractors">>, <<"myextractor">>}}}]).
> but neither of these work.
> Can somebody point out where I'm going wrong?
> --
> Greg
> Clipboard <http://www.clipboard.com> is hiring<http://www.clipboard.com/jobs>
> !

Clipboard <http://www.clipboard.com> is hiring<http://www.clipboard.com/jobs>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.basho.com/pipermail/riak-users_lists.basho.com/attachments/20110719/a07c527a/attachment.html>

More information about the riak-users mailing list