mirror of
https://github.com/valitydev/riak_test.git
synced 2024-11-06 08:35:22 +00:00
Remove search
Cocerned again about what this means for legacy -> previous tests, etc. Riak Test really isn't suitable for testing across versions.
This commit is contained in:
parent
3b8dce1d90
commit
6e9062fc1b
@ -42,9 +42,6 @@
|
|||||||
-define(KV_BUCKET, <<"vhm_kv">>).
|
-define(KV_BUCKET, <<"vhm_kv">>).
|
||||||
-define(KV_COUNT, 1000).
|
-define(KV_COUNT, 1000).
|
||||||
|
|
||||||
-define(SEARCH_BUCKET, <<"vhm_search">>).
|
|
||||||
-define(SEARCH_COUNT, 1000).
|
|
||||||
|
|
||||||
-define(PIPE_COUNT, 100).
|
-define(PIPE_COUNT, 100).
|
||||||
|
|
||||||
-define(FOLD_CAPABILITY, {riak_core,fold_req_version}).
|
-define(FOLD_CAPABILITY, {riak_core,fold_req_version}).
|
||||||
@ -54,10 +51,9 @@ confirm() ->
|
|||||||
UpgradeVsn = proplists:get_value(upgrade_version,
|
UpgradeVsn = proplists:get_value(upgrade_version,
|
||||||
riak_test_runner:metadata(),
|
riak_test_runner:metadata(),
|
||||||
previous),
|
previous),
|
||||||
SearchEnabled = [{riak_search, [{enabled, true}]}],
|
Versions = [{current, []},
|
||||||
Versions = [{current, SearchEnabled},
|
{UpgradeVsn, []}],
|
||||||
{UpgradeVsn, SearchEnabled}],
|
Services = [riak_kv, riak_pipe],
|
||||||
Services = [riak_kv, riak_search, riak_pipe],
|
|
||||||
[Current, Old] = Nodes = rt:deploy_nodes(Versions, Services),
|
[Current, Old] = Nodes = rt:deploy_nodes(Versions, Services),
|
||||||
|
|
||||||
prepare_vnodes(Current),
|
prepare_vnodes(Current),
|
||||||
@ -95,7 +91,6 @@ confirm() ->
|
|||||||
%% handoff when we join the other node
|
%% handoff when we join the other node
|
||||||
prepare_vnodes(Node) ->
|
prepare_vnodes(Node) ->
|
||||||
prepare_kv_vnodes(Node),
|
prepare_kv_vnodes(Node),
|
||||||
prepare_search_vnodes(Node),
|
|
||||||
prepare_pipe_vnodes(Node).
|
prepare_pipe_vnodes(Node).
|
||||||
|
|
||||||
prepare_kv_vnodes(Node) ->
|
prepare_kv_vnodes(Node) ->
|
||||||
@ -109,20 +104,6 @@ prepare_kv_vnodes(Node) ->
|
|||||||
[ list_to_binary(integer_to_list(N)) || N <- lists:seq(1, ?KV_COUNT) ]),
|
[ list_to_binary(integer_to_list(N)) || N <- lists:seq(1, ?KV_COUNT) ]),
|
||||||
riakc_pb_socket:stop(C).
|
riakc_pb_socket:stop(C).
|
||||||
|
|
||||||
prepare_search_vnodes(Node) ->
|
|
||||||
lager:info("Peparing Search vnodes with keys 1000-~b in bucket ~s",
|
|
||||||
[1000+?SEARCH_COUNT, ?SEARCH_BUCKET]),
|
|
||||||
rt:enable_search_hook(Node, ?SEARCH_BUCKET),
|
|
||||||
C = rt:pbc(Node),
|
|
||||||
lists:foreach(
|
|
||||||
fun(KV) ->
|
|
||||||
O = riakc_obj:new(?SEARCH_BUCKET, KV, KV, "text/plain"),
|
|
||||||
ok = riakc_pb_socket:put(C, O)
|
|
||||||
end,
|
|
||||||
[ list_to_binary(integer_to_list(N))
|
|
||||||
|| N <- lists:seq(1000, 1000+?SEARCH_COUNT) ]),
|
|
||||||
riakc_pb_socket:stop(C).
|
|
||||||
|
|
||||||
prepare_pipe_vnodes(Node) ->
|
prepare_pipe_vnodes(Node) ->
|
||||||
%% the riak_pipe_w_pass worker produces no archive, but the vnode
|
%% the riak_pipe_w_pass worker produces no archive, but the vnode
|
||||||
%% still sends its queue (even if empty) through handoff
|
%% still sends its queue (even if empty) through handoff
|
||||||
@ -143,7 +124,6 @@ check_logs() ->
|
|||||||
|
|
||||||
%% make sure all of our apps completed some handoff
|
%% make sure all of our apps completed some handoff
|
||||||
ExpectedApps = lists:sort([riak_kv_vnode,
|
ExpectedApps = lists:sort([riak_kv_vnode,
|
||||||
riak_search_vnode,
|
|
||||||
riak_pipe_vnode]),
|
riak_pipe_vnode]),
|
||||||
FoundApps = lists:sort([ A || {A, _} <- AppCounts ]),
|
FoundApps = lists:sort([ A || {A, _} <- AppCounts ]),
|
||||||
?assertEqual(ExpectedApps, FoundApps),
|
?assertEqual(ExpectedApps, FoundApps),
|
||||||
|
Loading…
Reference in New Issue
Block a user