Skip to content

Commit

Permalink
Renamed roll_search_query_list/1 to just be roll_list/1
Browse files Browse the repository at this point in the history
  • Loading branch information
nathanaschbacher committed Sep 13, 2013
1 parent 656544c commit 351b680
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/basho_bench_driver_riakc_pb.erl
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,7 @@ run(listkeys, _KeyGen, _ValueGen, State) ->
run(search, _KeyGen, _ValueGen, #state{search_queries=SearchQs}=State) ->
[{Index, Query, Options}|_] = SearchQs,

NewState = State#state{search_queries=roll_search_query_list(SearchQs)},
NewState = State#state{search_queries=roll_list(SearchQs)},

case riakc_pb_socket:search(NewState#state.pid, Index, Query, Options, NewState#state.timeout_read) of
{ok, _Results} ->
Expand All @@ -255,7 +255,7 @@ run(search_interval, _KeyGen, _ValueGen, #state{search_queries=SearchQs, start_t
Now = erlang:now(),
case timer:now_diff(Now, StartTime) of
_MicroSec when _MicroSec > (Interval * 1000000) ->
NewState = State#state{search_queries=roll_search_query_list(SearchQs),start_time=Now};
NewState = State#state{search_queries=roll_list(SearchQs),start_time=Now};
_MicroSec ->
NewState = State
end,
Expand Down Expand Up @@ -372,7 +372,7 @@ make_keylist(Bucket, KeyGen, Count) ->
[{Bucket, list_to_binary(KeyGen())}
|make_keylist(Bucket, KeyGen, Count-1)].

roll_search_query_list(List) ->
roll_list(List) ->
[lists:last(List) | lists:sublist(List, length(List) - 1)].

mapred_valgen(_Id, MaxRand) ->
Expand Down

0 comments on commit 351b680

Please sign in to comment.