diff options
Diffstat (limited to 'doc/src/manual/ranch_app.asciidoc')
-rw-r--r-- | doc/src/manual/ranch_app.asciidoc | 45 |
1 files changed, 39 insertions, 6 deletions
diff --git a/doc/src/manual/ranch_app.asciidoc b/doc/src/manual/ranch_app.asciidoc index f5b6e00..5eca83a 100644 --- a/doc/src/manual/ranch_app.asciidoc +++ b/doc/src/manual/ranch_app.asciidoc @@ -2,14 +2,42 @@ == Name -ranch - Socket acceptor pool for TCP protocols. +ranch - Socket acceptor pool for TCP protocols + +== Description + +Ranch is a socket acceptor pool for TCP protocols. + +Ranch manages listeners which are a set of processes that +accept and manage connections. The connection's transport +and protocol modules are configured per listener. Listeners +can be inspected and reconfigured without interruptions in +service. + +== Modules + +Functions: + +* link:man:ranch(3)[ranch(3)] - Socket acceptor pool +* link:man:ranch_ssl(3)[ranch_ssl(3)] - SSL transport +* link:man:ranch_tcp(3)[ranch_tcp(3)] - TLS transport + +Behaviors: + +* link:man:ranch_protocol(3)[ranch_protocol(3)] - Protocol modules +* link:man:ranch_transport(3)[ranch_transport(3)] - Transport modules == Dependencies -The `ranch` application depends on the `ssl` application to -start. It is used for handling secure connections, when the -transport is `ranch_ssl`. It can be disabled if SSL is not -used. +* ssl - Secure communication over sockets + +All these applications must be started before the `ranch` +application. To start Ranch and all dependencies at once: + +[source,erlang] +---- +{ok, _} = application:ensure_all_started(ranch). +---- == Environment @@ -17,8 +45,13 @@ The `ranch` application defines one application environment configuration parameter. profile (false):: - When enabled, Ranch will start `eprof` profiling automatically. +When enabled, Ranch will start `eprof` profiling automatically. ++ You can use the `ranch_app:profile_output/0` function to stop profiling and output the results to the files 'procs.profile' and 'total.profile'. Do not use in production. + +== See also + +ssl(7) |