Skip to content

Instantly share code, notes, and snippets.

@jrecursive
Created October 10, 2012 21:28
Show Gist options
  • Select an option

  • Save jrecursive/3868527 to your computer and use it in GitHub Desktop.

Select an option

Save jrecursive/3868527 to your computer and use it in GitHub Desktop.
bucket_coverage(Bucket) ->
VNodeSelector = allup,
BucketProps = riak_core_bucket:get_bucket(Bucket),
NVal = proplists:get_value(n_val, BucketProps),
PVC = 1,
ReqId = erlang:phash2(erlang:now()),
NodeCheckService = riak_kv,
{Nodes, _} = riak_core_coverage_plan:create_plan(VNodeSelector,
NVal,
PVC,
ReqId,
NodeCheckService),
Nodes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment