It’s worth noting that secondary indexes (2i) has some other advantages over solr search. If you _can_ model your queries in 2i then I'd recommend it.
Secondary indexes have a richer API than is currently documented, if you look at https://docs.basho.com/riak/1.4.7/dev/using/2i/ you’ll see that documents a feature that allows the index terms to be filtered via reg ex. There is also the feature that can return the actual riak objects for a $keys index search, You can pack the index terms with data and return the terms in a query so that you don’t need a further object fetch (see return_terms in docs.) Secondary indexes are written atomically with the object they index. Operationally they don’t require you run a JVM and Solr alongside your riak nodes. You have the tools with basho_bench to answer the question about performance and overhead for your workload. I suspect for “overhead” 2i wins, as there is no JVM-per-node. Modelling for 2i is perhaps harder, in the classical nosql way, you have to do more work upfront when designing your querying. I hope that helps a little. I worked quite a lot on 2i and never really understood why riak-search was seen as a replacment, imo they’re complementary, and you pick the one that best fits. Cheers Russell On 2 Feb 2017, at 09:43, Alex Feng <[email protected]> wrote: > Hello Riak-users, > > I am currently using Riak search to do some queries, since my queries are > very simple, it should be fulfilled by secondary indexes as well. > So, my question is which one has better performance and less overhead, let's > say both can fulfill the query requirement. > > Many thanks in advance. > > Br, > Alex > _______________________________________________ > riak-users mailing list > [email protected] > http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com _______________________________________________ riak-users mailing list [email protected] http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
