Bitcask Key Listing

2014-08-19 Thread Jason Campbell
I currently maintain my own indexes for some things, and use natural keys where I can, but a question has been nagging me lately. Why is key listing slow? Specifically, why is bitcask key listing slow? One of the biggest issues with bitcask is all keys (including the bucket name and some overh

Re: Fwd: RiakCS 504 Timeout on s3cmd for certain keys

2014-08-19 Thread Alex Millar
Hey Kota, We’re currently using the following versions; # Download RiakCS  # Version: 1.4.5 # OS: Ubuntu 12.04 (Precise) AMD 64 curl -O  http://s3.amazonaws.com/downloads.basho.com/riak-cs/1.4/1.4.5/ubuntu/precise/riak-cs_1.4.5-1_amd64.deb # Download Riak # Version: 1.4.8 # OS: Ubuntu 12.04 (Pre

Re: Bitcask Key Listing

2014-08-19 Thread Kelly McLaughlin
Jason, There are two aspects to to a key listing operation that make it expensive relative to normal gets or puts. The first part is that, due to the way data is distributed in Riak, key listing requires a covering set of vnodes to participate in order to determine the list of keys for a buck

Re: Fwd: RiakCS 504 Timeout on s3cmd for certain keys

2014-08-19 Thread Kelly McLaughlin
Alex, The value you had set for the fold_objects_for_list_keys setting is one I was very interested to see and I highly recommend setting it to true for your cluster. The impact of setting this to true should be to make bucket listing operations generally more efficient. There should be no det

Re: Riak Search Issue

2014-08-19 Thread Alex De la rosa
Hi Eric, You were right on naming the bucket the same as the index... it worked that way: bucket = client.bucket_type('futbolistas').bucket('famoso') results = bucket.search('name_s:Lion*') print results {'num_found': 2, 'max_score': 1.0, 'docs': [{u'age_i': u'30', u'name_s': u'Lionel', u'_yz_rk

Re: Riak Search Issue

2014-08-19 Thread Alex De la rosa
Hi Sean, Yeah, I opted to follow that pattern on my latest attempt as I see it more clear that the way in the documentation. Still same issue although with Eric we saw it works fine when index and bucket has the same name. Thanks! Alex On Mon, Aug 18, 2014 at 11:27 PM, Sean Cribbs wrote: > Do

Re: Did a force-remove of two nodes, now system is unresponsive

2014-08-19 Thread marcel.koopman
Hi, The configured ring size is 64 (default i believe). Is this something we can change now? Also still riak is doing transfers, making some of the nodes unresponsive. We've limited the transfers to 1. But how do we handle this? Kind regards, Marcel 2014-08-19 8:58 GMT+02:00 Ciprian Manea [via

Riak python client and Solr

2014-08-19 Thread Sapre, Meghna A
Hi, I am trying to use the group and stats options with riak search. I get expected results with http urls, but not with python-riak-client fulltext pbc search. Here’s what I’m trying to do: q = 'build.type:CI&group=on&group.field=build.version' try: search_results = riak_

Re: Riak python client and Solr

2014-08-19 Thread Eric Redmond
You don't pass in a query as a url encoded string, but rather a set of parameters. So you'd call something like: search_results = riak_client.fulltext_search(self.Result_Index, 'build.type:CI', group='on', 'group.field'='build.version') Eric On Aug 19, 2014, at 1:08 PM, Sapre, Meghna A wrote

Re: Riak python client and Solr

2014-08-19 Thread Alex De la rosa
Hi there, I was having the same problems too... this works fine: r = client.fulltext_search('ix_images', 'site_s:xxx AND keywords_s:yyy') but this gives the same error as yours: r = client.fulltext_search('ix_images', 'site_s:xxx AND keywords_s:yyy&sort="clickrate_f desc"') Then I saw this way

Re: Riak python client and Solr

2014-08-19 Thread Alex De la rosa
Seems I was wrong... the API doesn't complain but it doesn't perform the sorting as I thought it should do... any clues on how to do it? this: r = client.fulltext_search('ix_images', 'site_s:xxx AND keywords_s:yyy') plus sorting by "clickrate_f desc" Thanks! Alex On Tue, Aug 19, 2014 at 10:13

Re: Riak python client and Solr

2014-08-19 Thread Alex De la rosa
Ok, now I saw Sean's response... it worked perfectly that way :) r = client.fulltext_search('ix_images', 'site_s:aaa AND keywords_s:bbb', sort='clickrate_f asc') Thanks! Alex On Tue, Aug 19, 2014 at 10:17 PM, Alex De la rosa wrote: > Seems I was wrong... the API doesn't complain but it doesn'

RE: Riak python client and Solr

2014-08-19 Thread Sapre, Meghna A
Thanks Eric, It throws errors for 'group.field'='build.version'. search_results = riak_client.fulltext_search(self.Result_Index, 'build.type:CI', group='on', 'group.field'='build.version') Cannot appear past keyword arguments. I tried some variations of the same, did not seem to work Any sugge

How to call riak_core_ring:remove_member/3 from erlang shell?

2014-08-19 Thread Sebastian Wittenkamp
Hello all, riak shell newbie here. I have a cluster running Riak 1.0.0 which is showing duplicate entries in its ring_member list. E.g. I have 'riak@192.168.10.22' listed multiple times when I do 'riak-admin member_status'. If I tell the node to leave or force-remove it, only one entry is remo

Counters inside Maps

2014-08-19 Thread Alex De la rosa
Imagine I have a Riak object "footballer" with some static fields: name, team, number. I store them like this now: 1: CREATE INDEX FOR RIAK SEARCH curl -XPUT "http://148.251.140.229:8098/search/index/ix_footballers"; 2: CREATE BUCKET TYPE riak-admin bucket-type create tp_footballers '{"props":{"a

Re: Counters inside Maps

2014-08-19 Thread Sean Cribbs
Alex, Assuming you've already made your bucket-type with "map" as the datatype, then "bucket.new()" will return you a Map instead of a RiakObject. Translating your example above: key = bucket.new('lionelmessi') key.registers['name'].assign('Messi') key.registers['team'].assign('Barcelona') key.co

Re: Counters inside Maps

2014-08-19 Thread Luc Perkins
Alex, Do you mean a map as in a Python dict or as in a Riak map? If you want to create *footballers* as a Riak map, skip to the *Maps* section in this doc . That provides a full tutorial for dealing with other Data Types, such as counter

Re: Counters inside Maps

2014-08-19 Thread Alex De la rosa
Hi Sean, I didn't created the bucket_type as a map datatype as at first i was just testing simple Riak Search... then it occurred to me what if I want a counter in the data? :) Your example is pretty straightforward to follow and simple. Just 2 questions: 1. key.counters['number'].increment(1) =

Re: Counters inside Maps

2014-08-19 Thread Alex De la rosa
Hi Luc, Thanks for your link to the documentation; that was exactly what I saw on the data dump some time ago, didn't know it was published there :) Just one question regarding your example in contrast with Sean's... x.registers['name'].assign('Messi') x.registers['name_s'].assign('Messi') You

Re: Bitcask Key Listing

2014-08-19 Thread Jason Campbell
Hello Kelly, Thanks for the detailed response, but I'm still a bit confused. I understand the overhead over the covering set, and the key listing will only complete as fast as the slowest node. The data transfer shouldn't be much for a small key set though. So assuming we aren't doing someth

Re: Counters inside Maps

2014-08-19 Thread Sean Cribbs
On Tue, Aug 19, 2014 at 3:34 PM, Alex De la rosa wrote: > Hi Sean, > > I didn't created the bucket_type as a map datatype as at first i was just > testing simple Riak Search... then it occurred to me what if I want a > counter in the data? :) > > Your example is pretty straightforward to follow an

Re: Counters inside Maps

2014-08-19 Thread Alex De la rosa
Cool! Understood :) Thanks! Alex On Wednesday, August 20, 2014, Sean Cribbs wrote: > On Tue, Aug 19, 2014 at 3:34 PM, Alex De la rosa > > wrote: > > Hi Sean, > > > > I didn't created the bucket_type as a map datatype as at first i was just > > testing simple Riak Search... then it occurred to m

Is it a good practice to make riak a service and automatically start when the machine starts?

2014-08-19 Thread Gavin Huang
Hi, We have a little uncertainty in our team about whether to have riak automatically start when machine get rebooted. It do bring us some convenient if riak can start by default when machine crashed for some reason, and automatically restart. but i was wondering is there any case that auto

Re: Is it a good practice to make riak a service and automatically start when the machine starts?

2014-08-19 Thread Jared Morrow
Gavin, I think if you monitor the crash and reboot and take note or flag if it happens often, then that could be when you investigate the node more in depth. Having a node go up and down often is a sign clearly of something bad happening that should be investigated. For a rare reboot/crash, havi

Re: Is it a good practice to make riak a service and automatically start when the machine starts?

2014-08-19 Thread Gavin Huang
thanks for the quick reply, it make sense for me. On Wed, Aug 20, 2014 at 1:07 PM, Jared Morrow wrote: > Gavin, > > I think if you monitor the crash and reboot and take note or flag if it > happens often, then that could be when you investigate the node more in > depth. Having a node go up and