From e96a373c9699296ade966c601bb0e7185f4a163d Mon Sep 17 00:00:00 2001 From: Sverker Eriksson Date: Tue, 9 Aug 2016 20:07:47 +0200 Subject: kernel: Document net_kernel:getopts and setopts --- lib/kernel/doc/src/kernel_app.xml | 2 ++ lib/kernel/doc/src/net_kernel.xml | 36 ++++++++++++++++++++++++++++++++++++ 2 files changed, 38 insertions(+) (limited to 'lib/kernel/doc') diff --git a/lib/kernel/doc/src/kernel_app.xml b/lib/kernel/doc/src/kernel_app.xml index 9e6fb60bb7..dc0291babe 100644 --- a/lib/kernel/doc/src/kernel_app.xml +++ b/lib/kernel/doc/src/kernel_app.xml @@ -215,12 +215,14 @@

Defines the First..Last port range for the listener socket of a distributed Erlang node.

+ {inet_dist_listen_options, Opts}

Defines a list of extra socket options to be used when opening the listening socket for a distributed Erlang node. See gen_tcp:listen/2.

+ {inet_dist_connect_options, Opts}

Defines a list of extra socket options to be used when connecting to diff --git a/lib/kernel/doc/src/net_kernel.xml b/lib/kernel/doc/src/net_kernel.xml index f48a534d4f..3c1b3d5190 100644 --- a/lib/kernel/doc/src/net_kernel.xml +++ b/lib/kernel/doc/src/net_kernel.xml @@ -115,6 +115,21 @@ $ erl -sname foobar + + + Get distribution socket options. + +

Get one or more options for the distribution socket + connected to Node.

+

If Node is a connected node + the return value is the same as from + inet:getopts(Sock, Options) + where Sock is the distribution socket for Node.

+

Returns ignored if the local node is not alive or + {error, noconnection} if Node is not connected.

+ + + @@ -288,6 +303,27 @@ $ erl -sname foobar + + + Set distribution socket options. + +

Set one or more options for distribution sockets. + Argument Node can be either one node name + or the atom new to affect the distribution sockets of all + future connected nodes.

+

The return value is the same as from + inet:setopts/2 + or {error, noconnection} if Node is not + a connected node or new.

+

If Node is new the Options + will then also be added to kernel configration parameters + inet_dist_listen_options + and + inet_dist_connect_options.

+

Returns ignored if the local node is not alive.

+
+
+ start([Name]) -> {ok, pid()} | {error, Reason} start([Name, NameType]) -> {ok, pid()} | {error, Reason} -- cgit v1.2.3