riak refactor