basho/riak_kv — pull request #472 by jtuple (2013-01-28 21:46:57+00:00)
Title: Various minor AAE changes prompted by Riak 1.3 QA

This pull-request contains three changes to AAE based on on-going 1.3 release testing and LevelDB changes.

First, this pull-request makes calls between KV vnodes and `riak_kv_index_hashtree` synchronous, using calls rather than casts. This provides backpressure to the vnode if the hashtree writes cannot occur fast enough. Technically, this shouldn't happen. It happened during tests because LevelDB was unfairly throttling AAE writes, preventing AAE from making progress. This has since been changed. However, we want to play it safe and add backpressure anyway. Of course, this backpressure just shifts the problem. If hashtree writes can't happen fast enough, they we will have unbounded message queue growth somewhere. Without this pull-request, the growth would occur in a `riak_kv_index_hashtree` process, with this patch the growth occurs in a `riak_kv_vnode