Skip to content

Commit 99e2ae7

Browse files
davidwebster48bitwalker
authored andcommitted
Update docs for opts for HashRing.Managed.new/2
1 parent 1739f03 commit 99e2ae7

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

lib/managed_ring.ex

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,8 @@ defmodule HashRing.Managed do
2626
nodes: node_list,
2727
monitor_nodes: boolean,
2828
node_blacklist: pattern_list,
29-
node_whitelist: pattern_list
29+
node_whitelist: pattern_list,
30+
node_type: :all | :hidden | :visible
3031
]
3132

3233
@type child_spec_options :: [
@@ -65,6 +66,7 @@ defmodule HashRing.Managed do
6566
It takes an optional set of options which control how the ring behaves.
6667
Valid options are as follows:
6768
69+
* `nodes: list` - a list of nodes to initialize the ring.
6870
* `monitor_nodes: boolean` - will automatically monitor Erlang node membership,
6971
if new nodes are connected or nodes are disconnected, the ring will be updated automatically.
7072
In this configuration, nodes cannot be added or removed via the API. Those requests will be ignored.
@@ -74,7 +76,7 @@ defmodule HashRing.Managed do
7476
is provided, the blacklist has no effect.
7577
* `node_whitelist: [String.t | Regex.t]` - The same as `node_blacklist`, except the opposite; only nodes
7678
which match a pattern in the whitelist will result in the ring being updated.
77-
- `node_type: :all | :hidden | :visible`: refers what kind of nodes will be monitored
79+
* `node_type: :all | :hidden | :visible`: refers what kind of nodes will be monitored
7880
when `monitor_nodes` is `true`. For more information, see `:net_kernel.monitor_nodes/2`.
7981
8082
An error is returned if the ring already exists or if bad ring options are provided.

0 commit comments

Comments
 (0)