Putting Specific Bucket/Key Combination Gives Timeout

Russell Brown russell.brown at mac.com
Mon Mar 14 08:53:09 EDT 2011


Another approach is to generate a "random" bucket name at the start of your test and use that throughout the test , you can still delete the contents at the end of the test but the race condition isn't a problem for the next run (unless your random bucket name isn't very random). I use an UUID in the Java client integration tests.
On 14 Mar 2011, at 12:45, Sean Cribbs wrote:

> We are aware of some race-conditions caused by repeatedly accessing a key around DELETE requests.  Here's one bug:
> 
> https://issues.basho.com/show_bug.cgi?id=555
> 
> If you need to clear the data after a test run, I would suggest using the 'riak_kv_test_backend' from the Ripple project, or simply shut down Riak and delete the contents of the bitcask directory.
> 
> Sean Cribbs <sean at basho.com>
> Developer Advocate
> Basho Technologies, Inc.
> http://basho.com/
> 
> On Mar 14, 2011, at 8:27 AM, Runar Jordahl wrote:
> 
>> I am running unit tests against my single-node Riak database installed
>> on Ubuntu 10.10 64 bit. The tests write a few objects (key/value) to
>> the database, and then end by deleting all keys in the test bucket.
>> The test bucket is named “epigenttest”, the key I use is “test”.
>> 
>> Today the database entered a state where my default bucket/key used
>> for tests failed: If I tried doing a PUT using the following URL, I
>> got a timeout:
>> http://riaktest:8098/riak/epigenttest/test
>> 
>> However, if I modified the bucket or the key, the operation worked.
>> 
>> I could always reproduce the problem using bucket/key
>> epigenttest/test. I suspect that the database had corrupt data, which
>> prevented me from putting epigenttest/test.
>> 
>> Before running the unit test, Riak reported that the database was empty:
>> http://riaktest:8098/riak?buckets=true
>> {"buckets":[]}
>> 
>> I managed to get out of the problem by running “riak reboot”. I cannot
>> reproduce the problem again.
>> 
>> Could there be a bug in Riak when adding/deleting/putting the same
>> key? Below I include the result of running Riak Stats.
>> 
>> 
>> Kind regards
>> Runar Jordahl
>> 
>> 
>> 
>> http://riaktest:8098/stats
>> {
>>  "vnode_gets": 3,
>>  "vnode_puts": 0,
>>  "read_repairs": 0,
>>  "vnode_gets_total": 1277,
>>  "vnode_puts_total": 511,
>>  "node_gets": 1,
>>  "node_gets_total": 427,
>>  "node_get_fsm_time_mean": 25691.0,
>>  "node_get_fsm_time_median": 25691,
>>  "node_get_fsm_time_95": 25691,
>>  "node_get_fsm_time_99": 25691,
>>  "node_get_fsm_time_100": 25691,
>>  "node_puts": 1,
>>  "node_puts_total": 201,
>>  "node_put_fsm_time_mean": 60000872.0,
>>  "node_put_fsm_time_median": 60000872,
>>  "node_put_fsm_time_95": 60000872,
>>  "node_put_fsm_time_99": 60000872,
>>  "node_put_fsm_time_100": 60000872,
>>  "read_repairs_total": 5,
>>  "cpu_nprocs": 292,
>>  "cpu_avg1": 56,
>>  "cpu_avg5": 61,
>>  "cpu_avg15": 64,
>>  "mem_total": 1050324992,
>>  "mem_allocated": 521408512,
>>  "nodename": "riak at 127.0.0.1",
>>  "connected_nodes": [
>> 
>>  ],
>>  "sys_driver_version": "1.5",
>>  "sys_global_heaps_size": 0,
>>  "sys_heap_type": "private",
>>  "sys_logical_processors": 1,
>>  "sys_otp_release": "R13B04",
>>  "sys_process_count": 212,
>>  "sys_smp_support": false,
>>  "sys_system_version": "Erlang R13B04 (erts-5.7.5) [source] [rq:1]
>> [async-threads:64] [kernel-poll:true]",
>>  "sys_system_architecture": "i486-pc-linux-gnu",
>>  "sys_threads_enabled": true,
>>  "sys_thread_pool_size": 64,
>>  "sys_wordsize": 4,
>>  "ring_members": [
>>      "riak at 127.0.0.1"
>>  ],
>>  "ring_num_partitions": 64,
>>  "ring_ownership": "[{'riak at 127.0.0.1',64}]",
>>  "ring_creation_size": 64,
>>  "storage_backend": "riak_kv_bitcask_backend",
>>  "pbc_connects_total": 0,
>>  "pbc_connects": 0,
>>  "pbc_active": 0,
>>  "cluster_info_version": "1.0.0",
>>  "luwak_version": "1.0.0",
>>  "skerl_version": "1.0.0",
>>  "riak_kv_version": "0.14.0",
>>  "riak_core_version": "0.14.0",
>>  "bitcask_version": "1.1.5",
>>  "luke_version": "0.2.3",
>>  "webmachine_version": "1.8.0",
>>  "mochiweb_version": "1.7.1",
>>  "erlang_js_version": "0.5.0",
>>  "runtime_tools_version": "1.8.3",
>>  "crypto_version": "1.6.4",
>>  "os_mon_version": "2.2.5",
>>  "riak_err_version": "1.0.0",
>>  "sasl_version": "2.1.9",
>>  "stdlib_version": "1.16.5",
>>  "kernel_version": "2.13.5",
>>  "executing_mappers": 0
>> }
>> 
>> _______________________________________________
>> riak-users mailing list
>> riak-users at lists.basho.com
>> http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
> 
> 
> _______________________________________________
> riak-users mailing list
> riak-users at lists.basho.com
> http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.basho.com/pipermail/riak-users_lists.basho.com/attachments/20110314/25a2fd7a/attachment.html>


More information about the riak-users mailing list