Riak Search Issue

Luke Bakken lbakken at basho.com
Mon Aug 18 10:44:56 EDT 2014


Hi Alex -

You correctly created the "famous" index, as well as correctly
associated it with the bucket *type* "animals". Note that a bucket
type is not the same thing as a bucket in previous versions of Riak. A
bucket type is a way to give 1 or more buckets within that type the
same properties. You'll have to use different code in your Riak client
to use bucket types:

http://docs.basho.com/riak/2.0.0/dev/advanced/bucket-types/

--
Luke Bakken
CSE
lbakken at basho.com


On Mon, Aug 18, 2014 at 7:32 AM, Alex De la rosa
<alex.rosa.box at gmail.com> wrote:
> If I do this, I got the right index:
>
> http://RIAK:8098/search/index/famous
> => {"name":"famous","n_val":3,"schema":"_yz_default"}
>
> If I do this, I get an error:
> http://RIAK:8098/search/index/animals
> => not found
>
> What I don't understand is why it believes the index is the bucket name and
> not the index I created for it?
>
> riak-admin bucket-type create animals '{"props":{"search_index":"famous"}}'
> riak-admin bucket-type activate animals
>
> Shouldn't it be looking for a "famous" index instead of an "animals" index??
>
> Thanks!
> Alex
>
>
> On Mon, Aug 18, 2014 at 4:26 PM, Luke Bakken <lbakken at basho.com> wrote:
>>
>> What is the output of this command? Please replace RIAK_HOST and
>> "name_of_the_bucket" with the correct information:
>>
>> curl "$RIAK_HOST/search/index/name_of_the_bucket"
>>
>> If the above returns a 404, please use this guide to ensure you've
>> created the index correctly:
>>
>> http://docs.basho.com/riak/2.0.0/dev/using/search/
>>
>> If you expect the index to be there and it is not, the solr.log file
>> in /var/log/riak could provide a clue.
>>
>> --
>> Luke Bakken
>> CSE
>> lbakken at basho.com
>>
>>
>> On Mon, Aug 18, 2014 at 6:59 AM, Alex De la rosa
>> <alex.rosa.box at gmail.com> wrote:
>> > Hi there,
>> >
>> > I had been following the documentation [
>> > http://docs.basho.com/riak/2.0.0/dev/using/search/ ] about Riak Search
>> > and
>> > the code provided in the site doesn't seem to work?
>> >
>> > Everything I try ends up with an error saying no index found taking the
>> > name
>> > of the bucket as a not found index :(
>> >
>> > riak.RiakError: 'No index <<"name_of_the_bucket">> found.'
>> >
>> > Somebody knows what's going on?
>> >
>> > Thanks!
>> > Alex




More information about the riak-users mailing list