ranch:procs(3)

Name

ranch:procs - Retrieve pids from a listener

Description

procs(Ref  :: ranch:ref(),
      Type :: acceptors | connections)
    -> Pids :: [pid()]

Retrieve pids from a listener.

Arguments

Ref

The listener name.

Type

The type of process that will be returned.

Return value

A list of pids is returned.

Examples

Get the pids of the acceptor processes
Pids = ranch:procs(acceptors).
Get the pids of the connection processes
Pids = ranch:procs(connections).

See also

ranch:get_addr(3), ranch:get_port(3), ranch:info(3), ranch(3)

Ranch 1.7 Function Reference

Navigation

Version select