diff options
Diffstat (limited to 'docs/en/cowboy')
54 files changed, 1457 insertions, 262 deletions
diff --git a/docs/en/cowboy/1.0/index.html b/docs/en/cowboy/1.0/index.html index c1eedb2f..ea24e654 100644 --- a/docs/en/cowboy/1.0/index.html +++ b/docs/en/cowboy/1.0/index.html @@ -1 +1 @@ -<!DOCTYPE html><html><head><link rel="canonical" href="http://ninenines.eu/docs/"/><meta http-equiv="content-type" content="text/html; charset=utf-8" /><meta http-equiv="refresh" content="0;url=http://ninenines.eu/docs/" /></head></html>
\ No newline at end of file +<!DOCTYPE html><html><head><link rel="canonical" href="https://ninenines.eu/docs/"/><meta http-equiv="content-type" content="text/html; charset=utf-8" /><meta http-equiv="refresh" content="0;url=https://ninenines.eu/docs/" /></head></html>
\ No newline at end of file diff --git a/docs/en/cowboy/2.0/guide/architecture/index.html b/docs/en/cowboy/2.0/guide/architecture/index.html index 6f2015d6..0b3f8cb7 100644 --- a/docs/en/cowboy/2.0/guide/architecture/index.html +++ b/docs/en/cowboy/2.0/guide/architecture/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Architecture</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -127,13 +127,13 @@ only processing short-lived requests.</p></div> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/ws_handlers/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/ws_handlers/"> Websocket handlers </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/broken_clients/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/broken_clients/"> Dealing with broken clients </a> diff --git a/docs/en/cowboy/2.0/guide/broken_clients/index.html b/docs/en/cowboy/2.0/guide/broken_clients/index.html index dd8fb375..3860e51e 100644 --- a/docs/en/cowboy/2.0/guide/broken_clients/index.html +++ b/docs/en/cowboy/2.0/guide/broken_clients/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Dealing with broken clients</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -141,13 +141,13 @@ http://www.gnu.org/software/src-highlite --> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/architecture/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/architecture/"> Architecture </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/middlewares/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/middlewares/"> Middlewares </a> diff --git a/docs/en/cowboy/2.0/guide/constraints/index.html b/docs/en/cowboy/2.0/guide/constraints/index.html index 433c02da..10a80953 100644 --- a/docs/en/cowboy/2.0/guide/constraints/index.html +++ b/docs/en/cowboy/2.0/guide/constraints/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Constraints</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -183,13 +183,13 @@ to ensure that we do not crash when the input is invalid.</p></div> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/routing/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/routing/"> Routing </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/handlers/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/handlers/"> Handlers </a> diff --git a/docs/en/cowboy/2.0/guide/cookies/index.html b/docs/en/cowboy/2.0/guide/cookies/index.html index d516af72..2ea3e430 100644 --- a/docs/en/cowboy/2.0/guide/cookies/index.html +++ b/docs/en/cowboy/2.0/guide/cookies/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Using cookies</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -216,13 +216,13 @@ exception is thrown.</p></div> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/resp/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/resp/"> Sending a response </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/multipart/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/multipart/"> Multipart requests </a> diff --git a/docs/en/cowboy/2.0/guide/erlang_web/index.html b/docs/en/cowboy/2.0/guide/erlang_web/index.html index d2db7199..bd578340 100644 --- a/docs/en/cowboy/2.0/guide/erlang_web/index.html +++ b/docs/en/cowboy/2.0/guide/erlang_web/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Erlang and the Web</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -266,13 +266,13 @@ ebook version.</p></div> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/modern_web/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/modern_web/"> The modern Web </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/introduction/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/introduction/"> Introduction </a> diff --git a/docs/en/cowboy/2.0/guide/flow_diagram/index.html b/docs/en/cowboy/2.0/guide/flow_diagram/index.html index 79908680..7ec5684f 100644 --- a/docs/en/cowboy/2.0/guide/flow_diagram/index.html +++ b/docs/en/cowboy/2.0/guide/flow_diagram/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Flow diagram</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -79,13 +79,13 @@ <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/getting_started/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/getting_started/"> Getting started </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/listeners/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/listeners/"> Listeners </a> diff --git a/docs/en/cowboy/2.0/guide/getting_started/index.html b/docs/en/cowboy/2.0/guide/getting_started/index.html index 2e926dea..03e1dea7 100644 --- a/docs/en/cowboy/2.0/guide/getting_started/index.html +++ b/docs/en/cowboy/2.0/guide/getting_started/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Getting started</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -229,13 +229,13 @@ in your browser, you should get a nice <code>Hello Erlang!</code> displayed!</p> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/introduction/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/introduction/"> Introduction </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/flow_diagram/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/flow_diagram/"> Flow diagram </a> diff --git a/docs/en/cowboy/2.0/guide/handlers/index.html b/docs/en/cowboy/2.0/guide/handlers/index.html index 5826a1e7..b68527d9 100644 --- a/docs/en/cowboy/2.0/guide/handlers/index.html +++ b/docs/en/cowboy/2.0/guide/handlers/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Handlers</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -174,13 +174,13 @@ process will terminate soon after this call returns.</p></div> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/constraints/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/constraints/"> Constraints </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/loop_handlers/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/loop_handlers/"> Loop handlers </a> diff --git a/docs/en/cowboy/2.0/guide/hooks/index.html b/docs/en/cowboy/2.0/guide/hooks/index.html index 57d5baa6..00cf2d9e 100644 --- a/docs/en/cowboy/2.0/guide/hooks/index.html +++ b/docs/en/cowboy/2.0/guide/hooks/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Hooks</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -121,7 +121,7 @@ http://www.gnu.org/software/src-highlite --> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/sub_protocols/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/sub_protocols/"> Sub protocols </a> diff --git a/docs/en/cowboy/2.0/guide/index.html b/docs/en/cowboy/2.0/guide/index.html index d6403441..0d0a92e5 100644 --- a/docs/en/cowboy/2.0/guide/index.html +++ b/docs/en/cowboy/2.0/guide/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Cowboy User Guide</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> diff --git a/docs/en/cowboy/2.0/guide/introduction.asciidoc b/docs/en/cowboy/2.0/guide/introduction.asciidoc index d262b5ce..c9d042d3 100644 --- a/docs/en/cowboy/2.0/guide/introduction.asciidoc +++ b/docs/en/cowboy/2.0/guide/introduction.asciidoc @@ -1,7 +1,7 @@ [[introduction]] == Introduction -Cowboy is a small, fast and modular HTTP server written in Erlang. +Cowboy is a small, fast and modern HTTP server for Erlang/OTP. Cowboy aims to provide a complete xref:modern_web[modern Web stack]. This includes HTTP/1.1, HTTP/2, Websocket, Server-Sent Events and diff --git a/docs/en/cowboy/2.0/guide/introduction/index.html b/docs/en/cowboy/2.0/guide/introduction/index.html index db6f7b44..8aff6c8c 100644 --- a/docs/en/cowboy/2.0/guide/introduction/index.html +++ b/docs/en/cowboy/2.0/guide/introduction/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Introduction</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -69,7 +69,7 @@ <h1 class="lined-header"><span>Introduction</span></h1> -<div class="paragraph"><p>Cowboy is a small, fast and modular HTTP server written in Erlang.</p></div>
+<div class="paragraph"><p>Cowboy is a small, fast and modern HTTP server for Erlang/OTP.</p></div>
<div class="paragraph"><p>Cowboy aims to provide a complete <a href="../modern_web">modern Web stack</a>.
This includes HTTP/1.1, HTTP/2, Websocket, Server-Sent Events and
Webmachine-based REST.</p></div>
@@ -151,13 +151,13 @@ when sending responses.</p></div> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/erlang_web/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/erlang_web/"> Erlang and the Web </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/getting_started/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/getting_started/"> Getting started </a> diff --git a/docs/en/cowboy/2.0/guide/listeners/index.html b/docs/en/cowboy/2.0/guide/listeners/index.html index fa644115..40f1f1a3 100644 --- a/docs/en/cowboy/2.0/guide/listeners/index.html +++ b/docs/en/cowboy/2.0/guide/listeners/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Listeners</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -181,13 +181,13 @@ shared.</p></div> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/flow_diagram/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/flow_diagram/"> Flow diagram </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/routing/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/routing/"> Routing </a> diff --git a/docs/en/cowboy/2.0/guide/loop_handlers/index.html b/docs/en/cowboy/2.0/guide/loop_handlers/index.html index 15921152..5445f1cf 100644 --- a/docs/en/cowboy/2.0/guide/loop_handlers/index.html +++ b/docs/en/cowboy/2.0/guide/loop_handlers/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Loop handlers</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -220,13 +220,13 @@ accordingly.</p></div> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/handlers/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/handlers/"> Handlers </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/static_files/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/static_files/"> Static files </a> diff --git a/docs/en/cowboy/2.0/guide/middlewares/index.html b/docs/en/cowboy/2.0/guide/middlewares/index.html index f4dfdb0a..0bf012b3 100644 --- a/docs/en/cowboy/2.0/guide/middlewares/index.html +++ b/docs/en/cowboy/2.0/guide/middlewares/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Middlewares</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -164,13 +164,13 @@ values. It puts the result of the request handling into <code>result</code>.</p> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/broken_clients/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/broken_clients/"> Dealing with broken clients </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/sub_protocols/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/sub_protocols/"> Sub protocols </a> diff --git a/docs/en/cowboy/2.0/guide/modern_web/index.html b/docs/en/cowboy/2.0/guide/modern_web/index.html index bc720d03..7067288b 100644 --- a/docs/en/cowboy/2.0/guide/modern_web/index.html +++ b/docs/en/cowboy/2.0/guide/modern_web/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: The modern Web</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -187,7 +187,7 @@ the HTTP protocol.</p></div> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/erlang_web/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/erlang_web/"> Erlang and the Web </a> diff --git a/docs/en/cowboy/2.0/guide/multipart/index.html b/docs/en/cowboy/2.0/guide/multipart/index.html index f7c9202b..76ab89c1 100644 --- a/docs/en/cowboy/2.0/guide/multipart/index.html +++ b/docs/en/cowboy/2.0/guide/multipart/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Multipart requests</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -241,13 +241,13 @@ reading as soon as you find the data you need.</p></div> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/cookies/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/cookies/"> Using cookies </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/rest_principles/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/rest_principles/"> REST principles </a> diff --git a/docs/en/cowboy/2.0/guide/overview/index.html b/docs/en/cowboy/2.0/guide/overview/index.html index 914ca774..3d40ee48 100644 --- a/docs/en/cowboy/2.0/guide/overview/index.html +++ b/docs/en/cowboy/2.0/guide/overview/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Request overview</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> diff --git a/docs/en/cowboy/2.0/guide/req/index.html b/docs/en/cowboy/2.0/guide/req/index.html index 42e3c089..5ba6b035 100644 --- a/docs/en/cowboy/2.0/guide/req/index.html +++ b/docs/en/cowboy/2.0/guide/req/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: The Req object</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -480,13 +480,13 @@ client itself. It may also be a proxy or a gateway.</p></div> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/static_files/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/static_files/"> Static files </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/req_body/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/req_body/"> Reading the request body </a> diff --git a/docs/en/cowboy/2.0/guide/req_body/index.html b/docs/en/cowboy/2.0/guide/req_body/index.html index e9fb8512..139712a1 100644 --- a/docs/en/cowboy/2.0/guide/req_body/index.html +++ b/docs/en/cowboy/2.0/guide/req_body/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Reading the request body</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -216,13 +216,13 @@ http://www.gnu.org/software/src-highlite --> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/req/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/req/"> The Req object </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/resp/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/resp/"> Sending a response </a> diff --git a/docs/en/cowboy/2.0/guide/resource_design/index.html b/docs/en/cowboy/2.0/guide/resource_design/index.html index 23e7719e..bc37e2a4 100644 --- a/docs/en/cowboy/2.0/guide/resource_design/index.html +++ b/docs/en/cowboy/2.0/guide/resource_design/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Designing a resource handler</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -286,13 +286,13 @@ no way of knowing it has been completed yet, implement the <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/rest_flowcharts/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/rest_flowcharts/"> REST flowcharts </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/ws_protocol/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/ws_protocol/"> The Websocket protocol </a> diff --git a/docs/en/cowboy/2.0/guide/resp/index.html b/docs/en/cowboy/2.0/guide/resp/index.html index 9cff5403..6bf3cd8e 100644 --- a/docs/en/cowboy/2.0/guide/resp/index.html +++ b/docs/en/cowboy/2.0/guide/resp/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Sending a response</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -394,13 +394,13 @@ ultimately send a response to the client.</p></div> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/req_body/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/req_body/"> Reading the request body </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/cookies/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/cookies/"> Using cookies </a> diff --git a/docs/en/cowboy/2.0/guide/rest_flowcharts/index.html b/docs/en/cowboy/2.0/guide/rest_flowcharts/index.html index d76d3b14..77af893e 100644 --- a/docs/en/cowboy/2.0/guide/rest_flowcharts/index.html +++ b/docs/en/cowboy/2.0/guide/rest_flowcharts/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: REST flowcharts</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -316,13 +316,13 @@ the results for subsequent use.</p></div> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/rest_handlers/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/rest_handlers/"> REST handlers </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/resource_design/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/resource_design/"> Designing a resource handler </a> diff --git a/docs/en/cowboy/2.0/guide/rest_handlers/index.html b/docs/en/cowboy/2.0/guide/rest_handlers/index.html index 3caf83e0..2f656c70 100644 --- a/docs/en/cowboy/2.0/guide/rest_handlers/index.html +++ b/docs/en/cowboy/2.0/guide/rest_handlers/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: REST handlers</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -355,13 +355,13 @@ cellspacing="0" cellpadding="4"> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/rest_principles/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/rest_principles/"> REST principles </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/rest_flowcharts/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/rest_flowcharts/"> REST flowcharts </a> diff --git a/docs/en/cowboy/2.0/guide/rest_principles/index.html b/docs/en/cowboy/2.0/guide/rest_principles/index.html index 2e3ad8c1..a78b08ef 100644 --- a/docs/en/cowboy/2.0/guide/rest_principles/index.html +++ b/docs/en/cowboy/2.0/guide/rest_principles/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: REST principles</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -225,13 +225,13 @@ anything specific to the service to operate on it.</p></div> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/multipart/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/multipart/"> Multipart requests </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/rest_handlers/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/rest_handlers/"> REST handlers </a> diff --git a/docs/en/cowboy/2.0/guide/routing/index.html b/docs/en/cowboy/2.0/guide/routing/index.html index 9a04e323..ab7fe6a7 100644 --- a/docs/en/cowboy/2.0/guide/routing/index.html +++ b/docs/en/cowboy/2.0/guide/routing/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Routing</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -332,13 +332,13 @@ http://www.gnu.org/software/src-highlite --> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/listeners/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/listeners/"> Listeners </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/constraints/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/constraints/"> Constraints </a> diff --git a/docs/en/cowboy/2.0/guide/static_files/index.html b/docs/en/cowboy/2.0/guide/static_files/index.html index ff1c78dc..49a93eff 100644 --- a/docs/en/cowboy/2.0/guide/static_files/index.html +++ b/docs/en/cowboy/2.0/guide/static_files/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Static files</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -245,13 +245,13 @@ http://www.gnu.org/software/src-highlite --> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/loop_handlers/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/loop_handlers/"> Loop handlers </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/req/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/req/"> The Req object </a> diff --git a/docs/en/cowboy/2.0/guide/sub_protocols/index.html b/docs/en/cowboy/2.0/guide/sub_protocols/index.html index c8c7fbb3..d2437876 100644 --- a/docs/en/cowboy/2.0/guide/sub_protocols/index.html +++ b/docs/en/cowboy/2.0/guide/sub_protocols/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Sub protocols</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -142,13 +142,13 @@ the optional <code>terminate/3</code> callback is called, if present.</p></div> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/middlewares/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/middlewares/"> Middlewares </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/hooks/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/hooks/"> Hooks </a> diff --git a/docs/en/cowboy/2.0/guide/ws_handlers/index.html b/docs/en/cowboy/2.0/guide/ws_handlers/index.html index adcdc3e4..b8bf8d33 100644 --- a/docs/en/cowboy/2.0/guide/ws_handlers/index.html +++ b/docs/en/cowboy/2.0/guide/ws_handlers/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Websocket handlers</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -341,13 +341,13 @@ close frame will not be sent.</p></div> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/ws_protocol/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/ws_protocol/"> The Websocket protocol </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/architecture/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/architecture/"> Architecture </a> diff --git a/docs/en/cowboy/2.0/guide/ws_protocol/index.html b/docs/en/cowboy/2.0/guide/ws_protocol/index.html index 17d873d1..8d4d35e9 100644 --- a/docs/en/cowboy/2.0/guide/ws_protocol/index.html +++ b/docs/en/cowboy/2.0/guide/ws_protocol/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: The Websocket protocol</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -143,13 +143,13 @@ the listener.</p></div> <nav style="margin:1em 0"> - <a style="float:left" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/resource_design/"> + <a style="float:left" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/resource_design/"> Designing a resource handler </a> - <a style="float:right" href="http://ninenines.eu/docs/en/cowboy/2.0/guide/ws_handlers/"> + <a style="float:right" href="https://ninenines.eu/docs/en/cowboy/2.0/guide/ws_handlers/"> Websocket handlers </a> diff --git a/docs/en/cowboy/2.0/index.html b/docs/en/cowboy/2.0/index.html index c1eedb2f..ea24e654 100644 --- a/docs/en/cowboy/2.0/index.html +++ b/docs/en/cowboy/2.0/index.html @@ -1 +1 @@ -<!DOCTYPE html><html><head><link rel="canonical" href="http://ninenines.eu/docs/"/><meta http-equiv="content-type" content="text/html; charset=utf-8" /><meta http-equiv="refresh" content="0;url=http://ninenines.eu/docs/" /></head></html>
\ No newline at end of file +<!DOCTYPE html><html><head><link rel="canonical" href="https://ninenines.eu/docs/"/><meta http-equiv="content-type" content="text/html; charset=utf-8" /><meta http-equiv="refresh" content="0;url=https://ninenines.eu/docs/" /></head></html>
\ No newline at end of file diff --git a/docs/en/cowboy/2.0/manual/cowboy.set_env/index.html b/docs/en/cowboy/2.0/manual/cowboy.set_env/index.html new file mode 100644 index 00000000..bce57e3c --- /dev/null +++ b/docs/en/cowboy/2.0/manual/cowboy.set_env/index.html @@ -0,0 +1,255 @@ +<!DOCTYPE html> +<html lang="en"> + +<head> + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + <meta name="description" content=""> + <meta name="author" content="Loïc Hoguin based on a design from (Soft10) Pol Cámara"> + + <meta name="generator" content="Hugo 0.16" /> + + <title>Nine Nines: cowboy:set_env(3)</title> + + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + + <link href="/css/bootstrap.min.css" rel="stylesheet"> + <link href="/css/99s.css" rel="stylesheet"> + + <link rel="shortcut icon" href="/img/ico/favicon.ico"> + <link rel="apple-touch-icon-precomposed" sizes="114x114" href="/img/ico/apple-touch-icon-114.png"> + <link rel="apple-touch-icon-precomposed" sizes="72x72" href="/img/ico/apple-touch-icon-72.png"> + <link rel="apple-touch-icon-precomposed" href="/img/ico/apple-touch-icon-57.png"> + + +</head> + + +<body class=""> + <header id="page-head"> + <div id="topbar" class="container"> + <div class="row"> + <div class="span2"> + <h1 id="logo"><a href="/" title="99s">99s</a></h1> + </div> + <div class="span10"> + + <div id="side-header"> + <nav> + <ul> + <li><a title="Hear my thoughts" href="/articles">Articles</a></li> + <li><a title="Watch my talks" href="/talks">Talks</a></li> + <li class="active"><a title="Read the docs" href="/docs">Documentation</a></li> + <li><a title="Request my services" href="/services">Consulting & Training</a></li> + </ul> + </nav> + <ul id="social"> + <li> + <a href="https://github.com/ninenines" title="Check my Github repositories"><img src="/img/ico_github.png" data-hover="/img/ico_github_alt.png" alt="Github"></a> + </li> + <li> + <a title="Keep in touch!" href="http://twitter.com/lhoguin"><img src="/img/ico_microblog.png" data-hover="/img/ico_microblog_alt.png"></a> + </li> + <li> + <a title="Contact me" href="mailto:[email protected]"><img src="/img/ico_mail.png" data-hover="/img/ico_mail_alt.png"></a> + </li> + </ul> + </div> + </div> + </div> + </div> + + +</header> + +<div id="contents" class="two_col"> +<div class="container"> +<div class="row"> +<div id="docs" class="span9 maincol"> + +<h1 class="lined-header"><span>cowboy:set_env(3)</span></h1> + +<div class="sect1">
+<h2 id="_name">Name</h2>
+<div class="sectionbody">
+<div class="paragraph"><p>cowboy:set_env - Update a listener’s environment value</p></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_description">Description</h2>
+<div class="sectionbody">
+<div class="listingblock">
+<div class="content"><!-- Generator: GNU source-highlight 3.1.8
+by Lorenzo Bettini
+http://www.lorenzobettini.it
+http://www.gnu.org/software/src-highlite -->
+<pre><tt><span style="font-weight: bold"><span style="color: #000000">set_env</span></span>(<span style="color: #009900">Name</span> <span style="color: #990000">::</span> <span style="font-weight: bold"><span style="color: #000000">ranch:ref</span></span>(),
+ <span style="color: #009900">Key</span> <span style="color: #990000">::</span> <span style="font-weight: bold"><span style="color: #000080">atom</span></span>(),
+ <span style="color: #009900">Value</span> <span style="color: #990000">::</span> <span style="font-weight: bold"><span style="color: #000000">any</span></span>())
+ <span style="color: #990000">-></span> <span style="color: #FF6600">ok</span></tt></pre></div></div>
+<div class="paragraph"><p>Set or update an environment value for a previously started
+listener.</p></div>
+<div class="paragraph"><p>This is most useful for updating the routes dynamically,
+without having to restart the listener.</p></div>
+<div class="paragraph"><p>The new value will only be available to new connections.
+Pre-existing connections will still use the old value.</p></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_arguments">Arguments</h2>
+<div class="sectionbody">
+<div class="dlist"><dl>
+<dt class="hdlist1">
+Name
+</dt>
+<dd>
+<p>
+The name of the listener to update.
+</p>
+<div class="paragraph"><p>The name of the listener is the first argument given to the
+<a href="../cowboy.start_clear">cowboy:start_clear(3)</a>,
+<a href="../cowboy.start_tls">cowboy:start_tls(3)</a> or
+<a href="../ranch.start_listener">ranch:start_listener(3)</a> function.</p></div>
+</dd>
+<dt class="hdlist1">
+Key
+</dt>
+<dd>
+<p>
+The key in the environment map. Common keys include <code>dispatch</code>
+and <code>middlewares</code>.
+</p>
+</dd>
+<dt class="hdlist1">
+Value
+</dt>
+<dd>
+<p>
+The new value.
+</p>
+</dd>
+</dl></div>
+<div class="paragraph"><p>The type of the value differs depending on the key.</p></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_return_value">Return value</h2>
+<div class="sectionbody">
+<div class="paragraph"><p>The atom <code>ok</code> is returned on success.</p></div>
+<div class="paragraph"><p>An <code>exit:badarg</code> exception is thrown when the listener does
+not exist.</p></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_changelog">Changelog</h2>
+<div class="sectionbody">
+<div class="ulist"><ul>
+<li>
+<p>
+<strong>1.0</strong>: Function introduced.
+</p>
+</li>
+</ul></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_examples">Examples</h2>
+<div class="sectionbody">
+<div class="listingblock">
+<div class="title">Update a listener’s routes</div>
+<div class="content"><!-- Generator: GNU source-highlight 3.1.8
+by Lorenzo Bettini
+http://www.lorenzobettini.it
+http://www.gnu.org/software/src-highlite -->
+<pre><tt><span style="color: #009900">Dispatch</span> <span style="color: #990000">=</span> <span style="font-weight: bold"><span style="color: #000000">cowboy_router:compile</span></span>([
+ {<span style="color: #FF6600">'_'</span>, [
+ {<span style="color: #FF0000">"/"</span>, <span style="color: #FF6600">toppage_h</span>, []},
+ {<span style="color: #FF0000">"/ws"</span>, <span style="color: #FF6600">websocket_h</span>, []}
+ ]}
+]),
+
+<span style="font-weight: bold"><span style="color: #000000">cowboy:set_env</span></span>(<span style="color: #FF6600">example</span>, <span style="color: #FF6600">dispatch</span>, <span style="color: #009900">Dispatch</span>)<span style="color: #990000">.</span></tt></pre></div></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_see_also">See also</h2>
+<div class="sectionbody">
+<div class="paragraph"><p><a href="../cowboy">cowboy(3)</a>,
+<a href="../cowboy.start_clear">cowboy:start_clear(3)</a>,
+<a href="../cowboy.start_tls">cowboy:start_tls(3)</a>,
+<a href="../ranch.set_protocol_options">ranch:set_protocol_options(3)</a></p></div>
+</div>
+</div>
+ + + + + +</div> + +<div class="span3 sidecol"> + + +<h3> + Cowboy + 2.0 + Function Reference + +</h3> + +<ul> + + <li><a href="/docs/en/cowboy/2.0/guide">User Guide</a></li> + + + <li><a href="/docs/en/cowboy/2.0/manual">Function Reference</a></li> + + +</ul> + +<h4 id="docs-nav">Navigation</h4> + +<h4>Version select</h4> +<ul> + + + + <li><a href="/docs/en/cowboy/1.0/manual">1.0</a></li> + + <li><a href="/docs/en/cowboy/2.0/manual">2.0</a></li> + +</ul> + +</div> +</div> +</div> +</div> + + <footer> + <div class="container"> + <div class="row"> + <div class="span6"> + <p id="scroll-top"><a href="#">↑ Scroll to top</a></p> + <nav> + <ul> + <li><a href="mailto:[email protected]" title="Contact us">Contact us</a></li><li><a href="https://github.com/ninenines/ninenines.github.io" title="Github repository">Contribute to this site</a></li> + </ul> + </nav> + </div> + <div class="span6 credits"> + <p><img src="/img/footer_logo.png"></p> + <p>Copyright © Loïc Hoguin 2012-2016</p> + </div> + </div> + </div> + </footer> + + + <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script> + <script src="/js/bootstrap-carousel.js"></script> + <script src="/js/bootstrap-dropdown.js"></script> + <script src="/js/custom.js"></script> + </body> +</html> + + diff --git a/docs/en/cowboy/2.0/manual/cowboy.start_clear/index.html b/docs/en/cowboy/2.0/manual/cowboy.start_clear/index.html new file mode 100644 index 00000000..74ace743 --- /dev/null +++ b/docs/en/cowboy/2.0/manual/cowboy.start_clear/index.html @@ -0,0 +1,307 @@ +<!DOCTYPE html> +<html lang="en"> + +<head> + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + <meta name="description" content=""> + <meta name="author" content="Loïc Hoguin based on a design from (Soft10) Pol Cámara"> + + <meta name="generator" content="Hugo 0.16" /> + + <title>Nine Nines: cowboy:start_clear(3)</title> + + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + + <link href="/css/bootstrap.min.css" rel="stylesheet"> + <link href="/css/99s.css" rel="stylesheet"> + + <link rel="shortcut icon" href="/img/ico/favicon.ico"> + <link rel="apple-touch-icon-precomposed" sizes="114x114" href="/img/ico/apple-touch-icon-114.png"> + <link rel="apple-touch-icon-precomposed" sizes="72x72" href="/img/ico/apple-touch-icon-72.png"> + <link rel="apple-touch-icon-precomposed" href="/img/ico/apple-touch-icon-57.png"> + + +</head> + + +<body class=""> + <header id="page-head"> + <div id="topbar" class="container"> + <div class="row"> + <div class="span2"> + <h1 id="logo"><a href="/" title="99s">99s</a></h1> + </div> + <div class="span10"> + + <div id="side-header"> + <nav> + <ul> + <li><a title="Hear my thoughts" href="/articles">Articles</a></li> + <li><a title="Watch my talks" href="/talks">Talks</a></li> + <li class="active"><a title="Read the docs" href="/docs">Documentation</a></li> + <li><a title="Request my services" href="/services">Consulting & Training</a></li> + </ul> + </nav> + <ul id="social"> + <li> + <a href="https://github.com/ninenines" title="Check my Github repositories"><img src="/img/ico_github.png" data-hover="/img/ico_github_alt.png" alt="Github"></a> + </li> + <li> + <a title="Keep in touch!" href="http://twitter.com/lhoguin"><img src="/img/ico_microblog.png" data-hover="/img/ico_microblog_alt.png"></a> + </li> + <li> + <a title="Contact me" href="mailto:[email protected]"><img src="/img/ico_mail.png" data-hover="/img/ico_mail_alt.png"></a> + </li> + </ul> + </div> + </div> + </div> + </div> + + +</header> + +<div id="contents" class="two_col"> +<div class="container"> +<div class="row"> +<div id="docs" class="span9 maincol"> + +<h1 class="lined-header"><span>cowboy:start_clear(3)</span></h1> + +<div class="sect1">
+<h2 id="_name">Name</h2>
+<div class="sectionbody">
+<div class="paragraph"><p>cowboy:start_clear - Listen for connections using plain TCP</p></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_description">Description</h2>
+<div class="sectionbody">
+<div class="listingblock">
+<div class="content"><!-- Generator: GNU source-highlight 3.1.8
+by Lorenzo Bettini
+http://www.lorenzobettini.it
+http://www.gnu.org/software/src-highlite -->
+<pre><tt><span style="font-weight: bold"><span style="color: #000000">start_clear</span></span>(<span style="color: #009900">Name</span> <span style="color: #990000">::</span> <span style="font-weight: bold"><span style="color: #000000">ranch:ref</span></span>(),
+ <span style="color: #009900">NumAcceptors</span> <span style="color: #990000">::</span> <span style="font-weight: bold"><span style="color: #000000">non_neg_integer</span></span>(),
+ <span style="color: #009900">TransportOpts</span> <span style="color: #990000">::</span> <span style="font-weight: bold"><span style="color: #000000">ranch_tcp:opts</span></span>(),
+ <span style="color: #009900">ProtocolOpts</span> <span style="color: #990000">::</span> <span style="font-weight: bold"><span style="color: #000000">opts</span></span>())
+ <span style="color: #990000">-></span> {<span style="color: #FF6600">ok</span>, <span style="color: #009900">ListenerPid</span> <span style="color: #990000">::</span> <span style="font-weight: bold"><span style="color: #000080">pid</span></span>()}
+ | {<span style="color: #FF6600">error</span>, <span style="font-weight: bold"><span style="color: #000000">any</span></span>()}</tt></pre></div></div>
+<div class="paragraph"><p>Start listening for connections over a clear TCP channel.</p></div>
+<div class="paragraph"><p>Both HTTP/1.1 and HTTP/2 are supported on this listener.
+HTTP/2 has two methods of establishing a connection over
+a clear TCP channel. Both the upgrade and the prior knowledge
+methods are supported.</p></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_arguments">Arguments</h2>
+<div class="sectionbody">
+<div class="dlist"><dl>
+<dt class="hdlist1">
+Name
+</dt>
+<dd>
+<p>
+The listener name is used to refer to this listener in
+future calls, for example when stopping it or when
+updating the routes defined.
+</p>
+<div class="paragraph"><p>It can be any Erlang term. An atom is generally good enough,
+for example <code>api</code>, <code>my_app_clear</code> or <code>my_app_tls</code>.</p></div>
+</dd>
+<dt class="hdlist1">
+NumAcceptors
+</dt>
+<dd>
+<p>
+The number of acceptors is the number of processes that
+will accept connections. Tweak this value to improve the
+accept rate for incoming connections.
+</p>
+<div class="paragraph"><p>The ideal value is between 10 and 100 on most systems.
+Larger values may have the opposite effect and reduce the
+accept rate. It’s generally safe to start with a value of
+100 (or 10 on low memory systems). Then, when accept rates
+become a concern, measure the performance and update the
+value accordingly.</p></div>
+<div class="paragraph"><p>This value is unrelated to the maximum number of concurrent
+connections.</p></div>
+</dd>
+<dt class="hdlist1">
+TransportOpts
+</dt>
+<dd>
+<p>
+The transport options are where the TCP options, including
+the listener’s port number, are defined. Transport options
+are provided as a list of keys and values, for example
+<code>[{port, 8080}]</code>.
+</p>
+<div class="paragraph"><p>The available options are documented in the
+<a href="../ranch_tcp">ranch_tcp(3)</a> manual.</p></div>
+</dd>
+<dt class="hdlist1">
+ProtocolOpts
+</dt>
+<dd>
+<p>
+The protocol options are in a map containing all the options for
+the different protocols that may be involved when connecting
+to the listener, including HTTP/1.1 and HTTP/2 but also
+subprotocols like Websocket.
+</p>
+<div class="paragraph"><p>The HTTP/1.1 options are documented in the
+<a href="../cowboy_http">cowboy_http(3)</a> manual;
+the HTTP/2 options in
+<a href="../cowboy_http">cowboy_http2(3)</a>;
+and the Websocket options in
+<a href="../cowboy_websocket">cowboy_websocket(3)</a>.</p></div>
+</dd>
+</dl></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_return_value">Return value</h2>
+<div class="sectionbody">
+<div class="paragraph"><p>An ok tuple is returned on success. It contains the pid of
+the top-level supervisor for the listener.</p></div>
+<div class="paragraph"><p>An error tuple is returned on error. The error reason may
+be any Erlang term.</p></div>
+<div class="paragraph"><p>A common error is <code>eaddrinuse</code>. It indicates that the port
+configured for Cowboy is already in use.</p></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_changelog">Changelog</h2>
+<div class="sectionbody">
+<div class="ulist"><ul>
+<li>
+<p>
+<strong>2.0</strong>: HTTP/2 support added.
+</p>
+</li>
+<li>
+<p>
+<strong>2.0</strong>: Function introduced. Replaces <code>cowboy:start_http/4</code>.
+</p>
+</li>
+</ul></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_examples">Examples</h2>
+<div class="sectionbody">
+<div class="listingblock">
+<div class="title">Start a listener</div>
+<div class="content"><!-- Generator: GNU source-highlight 3.1.8
+by Lorenzo Bettini
+http://www.lorenzobettini.it
+http://www.gnu.org/software/src-highlite -->
+<pre><tt><span style="color: #009900">Dispatch</span> <span style="color: #990000">=</span> <span style="font-weight: bold"><span style="color: #000000">cowboy_router:compile</span></span>([
+ {<span style="color: #FF6600">'_'</span>, [
+ {<span style="color: #FF0000">"/"</span>, <span style="color: #FF6600">toppage_h</span>, []}
+ ]}
+]),
+
+{<span style="color: #FF6600">ok</span>, <span style="color: #990000">_</span>} <span style="color: #990000">=</span> <span style="font-weight: bold"><span style="color: #000000">cowboy:start_clear</span></span>(<span style="color: #FF6600">example</span>, <span style="color: #993399">100</span>, [{<span style="color: #FF6600">port</span>, <span style="color: #993399">8080</span>}], #{
+ <span style="color: #0000FF">env</span> <span style="color: #990000">=></span> #{<span style="color: #0000FF">dispatch</span> <span style="color: #990000">=></span> <span style="color: #009900">Dispatch</span>}
+})<span style="color: #990000">.</span></tt></pre></div></div>
+<div class="listingblock">
+<div class="title">Start a listener on a random port</div>
+<div class="content"><!-- Generator: GNU source-highlight 3.1.8
+by Lorenzo Bettini
+http://www.lorenzobettini.it
+http://www.gnu.org/software/src-highlite -->
+<pre><tt><span style="color: #009900">Name</span> <span style="color: #990000">=</span> <span style="color: #FF6600">example</span>,
+
+{<span style="color: #FF6600">ok</span>, <span style="color: #990000">_</span>} <span style="color: #990000">=</span> <span style="font-weight: bold"><span style="color: #000000">cowboy:start_clear</span></span>(<span style="color: #009900">Name</span>, <span style="color: #993399">100</span>, [], #{
+ <span style="color: #0000FF">env</span> <span style="color: #990000">=></span> #{<span style="color: #0000FF">dispatch</span> <span style="color: #990000">=></span> <span style="color: #009900">Dispatch</span>}
+}),
+
+<span style="color: #009900">Port</span> <span style="color: #990000">=</span> <span style="font-weight: bold"><span style="color: #000000">ranch:get_port</span></span>(<span style="color: #009900">Name</span>)<span style="color: #990000">.</span></tt></pre></div></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_see_also">See also</h2>
+<div class="sectionbody">
+<div class="paragraph"><p><a href="../cowboy">cowboy(3)</a>,
+<a href="../cowboy.start_tls">cowboy:start_tls(3)</a>,
+<a href="../ranch">ranch(3)</a></p></div>
+</div>
+</div>
+ + + + + +</div> + +<div class="span3 sidecol"> + + +<h3> + Cowboy + 2.0 + Function Reference + +</h3> + +<ul> + + <li><a href="/docs/en/cowboy/2.0/guide">User Guide</a></li> + + + <li><a href="/docs/en/cowboy/2.0/manual">Function Reference</a></li> + + +</ul> + +<h4 id="docs-nav">Navigation</h4> + +<h4>Version select</h4> +<ul> + + + + <li><a href="/docs/en/cowboy/1.0/manual">1.0</a></li> + + <li><a href="/docs/en/cowboy/2.0/manual">2.0</a></li> + +</ul> + +</div> +</div> +</div> +</div> + + <footer> + <div class="container"> + <div class="row"> + <div class="span6"> + <p id="scroll-top"><a href="#">↑ Scroll to top</a></p> + <nav> + <ul> + <li><a href="mailto:[email protected]" title="Contact us">Contact us</a></li><li><a href="https://github.com/ninenines/ninenines.github.io" title="Github repository">Contribute to this site</a></li> + </ul> + </nav> + </div> + <div class="span6 credits"> + <p><img src="/img/footer_logo.png"></p> + <p>Copyright © Loïc Hoguin 2012-2016</p> + </div> + </div> + </div> + </footer> + + + <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script> + <script src="/js/bootstrap-carousel.js"></script> + <script src="/js/bootstrap-dropdown.js"></script> + <script src="/js/custom.js"></script> + </body> +</html> + + diff --git a/docs/en/cowboy/2.0/manual/cowboy.start_tls/index.html b/docs/en/cowboy/2.0/manual/cowboy.start_tls/index.html new file mode 100644 index 00000000..87ed2b83 --- /dev/null +++ b/docs/en/cowboy/2.0/manual/cowboy.start_tls/index.html @@ -0,0 +1,312 @@ +<!DOCTYPE html> +<html lang="en"> + +<head> + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + <meta name="description" content=""> + <meta name="author" content="Loïc Hoguin based on a design from (Soft10) Pol Cámara"> + + <meta name="generator" content="Hugo 0.16" /> + + <title>Nine Nines: cowboy:start_tls(3)</title> + + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + + <link href="/css/bootstrap.min.css" rel="stylesheet"> + <link href="/css/99s.css" rel="stylesheet"> + + <link rel="shortcut icon" href="/img/ico/favicon.ico"> + <link rel="apple-touch-icon-precomposed" sizes="114x114" href="/img/ico/apple-touch-icon-114.png"> + <link rel="apple-touch-icon-precomposed" sizes="72x72" href="/img/ico/apple-touch-icon-72.png"> + <link rel="apple-touch-icon-precomposed" href="/img/ico/apple-touch-icon-57.png"> + + +</head> + + +<body class=""> + <header id="page-head"> + <div id="topbar" class="container"> + <div class="row"> + <div class="span2"> + <h1 id="logo"><a href="/" title="99s">99s</a></h1> + </div> + <div class="span10"> + + <div id="side-header"> + <nav> + <ul> + <li><a title="Hear my thoughts" href="/articles">Articles</a></li> + <li><a title="Watch my talks" href="/talks">Talks</a></li> + <li class="active"><a title="Read the docs" href="/docs">Documentation</a></li> + <li><a title="Request my services" href="/services">Consulting & Training</a></li> + </ul> + </nav> + <ul id="social"> + <li> + <a href="https://github.com/ninenines" title="Check my Github repositories"><img src="/img/ico_github.png" data-hover="/img/ico_github_alt.png" alt="Github"></a> + </li> + <li> + <a title="Keep in touch!" href="http://twitter.com/lhoguin"><img src="/img/ico_microblog.png" data-hover="/img/ico_microblog_alt.png"></a> + </li> + <li> + <a title="Contact me" href="mailto:[email protected]"><img src="/img/ico_mail.png" data-hover="/img/ico_mail_alt.png"></a> + </li> + </ul> + </div> + </div> + </div> + </div> + + +</header> + +<div id="contents" class="two_col"> +<div class="container"> +<div class="row"> +<div id="docs" class="span9 maincol"> + +<h1 class="lined-header"><span>cowboy:start_tls(3)</span></h1> + +<div class="sect1">
+<h2 id="_name">Name</h2>
+<div class="sectionbody">
+<div class="paragraph"><p>cowboy:start_tls - Listen for connections using TLS</p></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_description">Description</h2>
+<div class="sectionbody">
+<div class="listingblock">
+<div class="content"><!-- Generator: GNU source-highlight 3.1.8
+by Lorenzo Bettini
+http://www.lorenzobettini.it
+http://www.gnu.org/software/src-highlite -->
+<pre><tt><span style="font-weight: bold"><span style="color: #000000">start_tls</span></span>(<span style="color: #009900">Name</span> <span style="color: #990000">::</span> <span style="font-weight: bold"><span style="color: #000000">ranch:ref</span></span>(),
+ <span style="color: #009900">NumAcceptors</span> <span style="color: #990000">::</span> <span style="font-weight: bold"><span style="color: #000000">non_neg_integer</span></span>(),
+ <span style="color: #009900">TransportOpts</span> <span style="color: #990000">::</span> <span style="font-weight: bold"><span style="color: #000000">ranch_ssl:opts</span></span>(),
+ <span style="color: #009900">ProtocolOpts</span> <span style="color: #990000">::</span> <span style="font-weight: bold"><span style="color: #000000">opts</span></span>())
+ <span style="color: #990000">-></span> {<span style="color: #FF6600">ok</span>, <span style="color: #009900">ListenerPid</span> <span style="color: #990000">::</span> <span style="font-weight: bold"><span style="color: #000080">pid</span></span>()}
+ | {<span style="color: #FF6600">error</span>, <span style="font-weight: bold"><span style="color: #000000">any</span></span>()}</tt></pre></div></div>
+<div class="paragraph"><p>Start listening for connections over a secure TLS channel.</p></div>
+<div class="paragraph"><p>Both HTTP/1.1 and HTTP/2 are supported on this listener.
+The ALPN TLS extension must be used to initiate an HTTP/2
+connection.</p></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_arguments">Arguments</h2>
+<div class="sectionbody">
+<div class="dlist"><dl>
+<dt class="hdlist1">
+Name
+</dt>
+<dd>
+<p>
+The listener name is used to refer to this listener in
+future calls, for example when stopping it or when
+updating the routes defined.
+</p>
+<div class="paragraph"><p>It can be any Erlang term. An atom is generally good enough,
+for example <code>api</code>, <code>my_app_clear</code> or <code>my_app_tls</code>.</p></div>
+</dd>
+<dt class="hdlist1">
+NumAcceptors
+</dt>
+<dd>
+<p>
+The number of acceptors is the number of processes that
+will accept connections. Tweak this value to improve the
+accept rate for incoming connections.
+</p>
+<div class="paragraph"><p>The ideal value is between 10 and 100 on most systems.
+Larger values may have the opposite effect and reduce the
+accept rate. It’s generally safe to start with a value of
+100 (or 10 on low memory systems). Then, when accept rates
+become a concern, measure the performance and update the
+value accordingly.</p></div>
+<div class="paragraph"><p>This value is unrelated to the maximum number of concurrent
+connections.</p></div>
+</dd>
+<dt class="hdlist1">
+TransportOpts
+</dt>
+<dd>
+<p>
+The transport options are where the TCP options, including
+the listener’s port number, are defined. They also contain
+the TLS options, like the server’s certificate. Transport options
+are provided as a list of keys and values, for example
+<code>[{port, 8443}, {certfile, "path/to/cert.pem"}]</code>.
+</p>
+<div class="paragraph"><p>The available options are documented in the
+<a href="../ranch_ssl">ranch_ssl(3)</a> manual.</p></div>
+</dd>
+<dt class="hdlist1">
+ProtocolOpts
+</dt>
+<dd>
+<p>
+The protocol options are in a map containing all the options for
+the different protocols that may be involved when connecting
+to the listener, including HTTP/1.1 and HTTP/2 but also
+subprotocols like Websocket.
+</p>
+<div class="paragraph"><p>The HTTP/1.1 options are documented in the
+<a href="../cowboy_http">cowboy_http(3)</a> manual;
+the HTTP/2 options in
+<a href="../cowboy_http">cowboy_http2(3)</a>;
+and the Websocket options in
+<a href="../cowboy_websocket">cowboy_websocket(3)</a>.</p></div>
+</dd>
+</dl></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_return_value">Return value</h2>
+<div class="sectionbody">
+<div class="paragraph"><p>An ok tuple is returned on success. It contains the pid of
+the top-level supervisor for the listener.</p></div>
+<div class="paragraph"><p>An error tuple is returned on error. The error reason may
+be any Erlang term.</p></div>
+<div class="paragraph"><p>A common error is <code>eaddrinuse</code>. It indicates that the port
+configured for Cowboy is already in use.</p></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_changelog">Changelog</h2>
+<div class="sectionbody">
+<div class="ulist"><ul>
+<li>
+<p>
+<strong>2.0</strong>: HTTP/2 support added.
+</p>
+</li>
+<li>
+<p>
+<strong>2.0</strong>: Function introduced. Replaces <code>cowboy:start_https/4</code>.
+</p>
+</li>
+</ul></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_examples">Examples</h2>
+<div class="sectionbody">
+<div class="listingblock">
+<div class="title">Start a listener</div>
+<div class="content"><!-- Generator: GNU source-highlight 3.1.8
+by Lorenzo Bettini
+http://www.lorenzobettini.it
+http://www.gnu.org/software/src-highlite -->
+<pre><tt><span style="color: #009900">Dispatch</span> <span style="color: #990000">=</span> <span style="font-weight: bold"><span style="color: #000000">cowboy_router:compile</span></span>([
+ {<span style="color: #FF6600">'_'</span>, [
+ {<span style="color: #FF0000">"/"</span>, <span style="color: #FF6600">toppage_h</span>, []}
+ ]}
+]),
+
+{<span style="color: #FF6600">ok</span>, <span style="color: #990000">_</span>} <span style="color: #990000">=</span> <span style="font-weight: bold"><span style="color: #000000">cowboy:start_tls</span></span>(<span style="color: #FF6600">example</span>, <span style="color: #993399">100</span>, [
+ {<span style="color: #FF6600">port</span>, <span style="color: #993399">8443</span>},
+ {<span style="color: #FF6600">cert</span>, <span style="color: #FF0000">"path/to/cert.pem"</span>}
+], #{
+ <span style="color: #0000FF">env</span> <span style="color: #990000">=></span> #{<span style="color: #0000FF">dispatch</span> <span style="color: #990000">=></span> <span style="color: #009900">Dispatch</span>}
+})<span style="color: #990000">.</span></tt></pre></div></div>
+<div class="listingblock">
+<div class="title">Start a listener on a random port</div>
+<div class="content"><!-- Generator: GNU source-highlight 3.1.8
+by Lorenzo Bettini
+http://www.lorenzobettini.it
+http://www.gnu.org/software/src-highlite -->
+<pre><tt><span style="color: #009900">Name</span> <span style="color: #990000">=</span> <span style="color: #FF6600">example</span>,
+
+{<span style="color: #FF6600">ok</span>, <span style="color: #990000">_</span>} <span style="color: #990000">=</span> <span style="font-weight: bold"><span style="color: #000000">cowboy:start_tls</span></span>(<span style="color: #009900">Name</span>, <span style="color: #993399">100</span>, [
+ {<span style="color: #FF6600">cert</span>, <span style="color: #FF0000">"path/to/cert.pem"</span>}
+], #{
+ <span style="color: #0000FF">env</span> <span style="color: #990000">=></span> #{<span style="color: #0000FF">dispatch</span> <span style="color: #990000">=></span> <span style="color: #009900">Dispatch</span>}
+}),
+
+<span style="color: #009900">Port</span> <span style="color: #990000">=</span> <span style="font-weight: bold"><span style="color: #000000">ranch:get_port</span></span>(<span style="color: #009900">Name</span>)<span style="color: #990000">.</span></tt></pre></div></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_see_also">See also</h2>
+<div class="sectionbody">
+<div class="paragraph"><p><a href="../cowboy">cowboy(3)</a>,
+<a href="../cowboy.start_clear">cowboy:start_clear(3)</a>,
+<a href="../ranch">ranch(3)</a></p></div>
+</div>
+</div>
+ + + + + +</div> + +<div class="span3 sidecol"> + + +<h3> + Cowboy + 2.0 + Function Reference + +</h3> + +<ul> + + <li><a href="/docs/en/cowboy/2.0/guide">User Guide</a></li> + + + <li><a href="/docs/en/cowboy/2.0/manual">Function Reference</a></li> + + +</ul> + +<h4 id="docs-nav">Navigation</h4> + +<h4>Version select</h4> +<ul> + + + + <li><a href="/docs/en/cowboy/1.0/manual">1.0</a></li> + + <li><a href="/docs/en/cowboy/2.0/manual">2.0</a></li> + +</ul> + +</div> +</div> +</div> +</div> + + <footer> + <div class="container"> + <div class="row"> + <div class="span6"> + <p id="scroll-top"><a href="#">↑ Scroll to top</a></p> + <nav> + <ul> + <li><a href="mailto:[email protected]" title="Contact us">Contact us</a></li><li><a href="https://github.com/ninenines/ninenines.github.io" title="Github repository">Contribute to this site</a></li> + </ul> + </nav> + </div> + <div class="span6 credits"> + <p><img src="/img/footer_logo.png"></p> + <p>Copyright © Loïc Hoguin 2012-2016</p> + </div> + </div> + </div> + </footer> + + + <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script> + <script src="/js/bootstrap-carousel.js"></script> + <script src="/js/bootstrap-dropdown.js"></script> + <script src="/js/custom.js"></script> + </body> +</html> + + diff --git a/docs/en/cowboy/2.0/manual/cowboy.stop_listener/index.html b/docs/en/cowboy/2.0/manual/cowboy.stop_listener/index.html new file mode 100644 index 00000000..832f9362 --- /dev/null +++ b/docs/en/cowboy/2.0/manual/cowboy.stop_listener/index.html @@ -0,0 +1,225 @@ +<!DOCTYPE html> +<html lang="en"> + +<head> + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1.0"> + <meta name="description" content=""> + <meta name="author" content="Loïc Hoguin based on a design from (Soft10) Pol Cámara"> + + <meta name="generator" content="Hugo 0.16" /> + + <title>Nine Nines: cowboy:stop_listener(3)</title> + + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + + <link href="/css/bootstrap.min.css" rel="stylesheet"> + <link href="/css/99s.css" rel="stylesheet"> + + <link rel="shortcut icon" href="/img/ico/favicon.ico"> + <link rel="apple-touch-icon-precomposed" sizes="114x114" href="/img/ico/apple-touch-icon-114.png"> + <link rel="apple-touch-icon-precomposed" sizes="72x72" href="/img/ico/apple-touch-icon-72.png"> + <link rel="apple-touch-icon-precomposed" href="/img/ico/apple-touch-icon-57.png"> + + +</head> + + +<body class=""> + <header id="page-head"> + <div id="topbar" class="container"> + <div class="row"> + <div class="span2"> + <h1 id="logo"><a href="/" title="99s">99s</a></h1> + </div> + <div class="span10"> + + <div id="side-header"> + <nav> + <ul> + <li><a title="Hear my thoughts" href="/articles">Articles</a></li> + <li><a title="Watch my talks" href="/talks">Talks</a></li> + <li class="active"><a title="Read the docs" href="/docs">Documentation</a></li> + <li><a title="Request my services" href="/services">Consulting & Training</a></li> + </ul> + </nav> + <ul id="social"> + <li> + <a href="https://github.com/ninenines" title="Check my Github repositories"><img src="/img/ico_github.png" data-hover="/img/ico_github_alt.png" alt="Github"></a> + </li> + <li> + <a title="Keep in touch!" href="http://twitter.com/lhoguin"><img src="/img/ico_microblog.png" data-hover="/img/ico_microblog_alt.png"></a> + </li> + <li> + <a title="Contact me" href="mailto:[email protected]"><img src="/img/ico_mail.png" data-hover="/img/ico_mail_alt.png"></a> + </li> + </ul> + </div> + </div> + </div> + </div> + + +</header> + +<div id="contents" class="two_col"> +<div class="container"> +<div class="row"> +<div id="docs" class="span9 maincol"> + +<h1 class="lined-header"><span>cowboy:stop_listener(3)</span></h1> + +<div class="sect1">
+<h2 id="_name">Name</h2>
+<div class="sectionbody">
+<div class="paragraph"><p>cowboy:stop_listener - Stop the given listener</p></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_description">Description</h2>
+<div class="sectionbody">
+<div class="listingblock">
+<div class="content"><!-- Generator: GNU source-highlight 3.1.8
+by Lorenzo Bettini
+http://www.lorenzobettini.it
+http://www.gnu.org/software/src-highlite -->
+<pre><tt><span style="font-weight: bold"><span style="color: #000000">stop_listener</span></span>(<span style="color: #009900">Name</span> <span style="color: #990000">::</span> <span style="font-weight: bold"><span style="color: #000000">ranch:ref</span></span>())
+ <span style="color: #990000">-></span> <span style="color: #FF6600">ok</span> | {<span style="color: #FF6600">error</span>, <span style="color: #FF6600">not_found</span>}<span style="color: #990000">.</span></tt></pre></div></div>
+<div class="paragraph"><p>Stop a previously started listener.</p></div>
+<div class="paragraph"><p>Alias of <a href="../ranch.stop_listener">ranch:stop_listener(3)</a>.</p></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_arguments">Arguments</h2>
+<div class="sectionbody">
+<div class="dlist"><dl>
+<dt class="hdlist1">
+Name
+</dt>
+<dd>
+<p>
+The name of the listener to be stopped.
+</p>
+<div class="paragraph"><p>The name of the listener is the first argument given to the
+<a href="../cowboy.start_clear">cowboy:start_clear(3)</a>,
+<a href="../cowboy.start_tls">cowboy:start_tls(3)</a> or
+<a href="../ranch.start_listener">ranch:start_listener(3)</a> function.</p></div>
+</dd>
+</dl></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_return_value">Return value</h2>
+<div class="sectionbody">
+<div class="paragraph"><p>The atom <code>ok</code> is returned on success.</p></div>
+<div class="paragraph"><p>The <code>{error, not_found}</code> tuple is returned when the listener
+does not exist.</p></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_changelog">Changelog</h2>
+<div class="sectionbody">
+<div class="ulist"><ul>
+<li>
+<p>
+<strong>1.0</strong>: Function introduced.
+</p>
+</li>
+</ul></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_examples">Examples</h2>
+<div class="sectionbody">
+<div class="listingblock">
+<div class="title">Stop a listener</div>
+<div class="content"><!-- Generator: GNU source-highlight 3.1.8
+by Lorenzo Bettini
+http://www.lorenzobettini.it
+http://www.gnu.org/software/src-highlite -->
+<pre><tt><span style="color: #0000FF">ok</span> <span style="color: #990000">=</span> <span style="font-weight: bold"><span style="color: #000000">cowboy:stop_listener</span></span>(<span style="color: #FF6600">example</span>)<span style="color: #990000">.</span></tt></pre></div></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_see_also">See also</h2>
+<div class="sectionbody">
+<div class="paragraph"><p><a href="../cowboy">cowboy(3)</a>,
+<a href="../cowboy.start_clear">cowboy:start_clear(3)</a>,
+<a href="../cowboy.start_tls">cowboy:start_tls(3)</a>,
+<a href="../ranch">ranch(3)</a>,
+<a href="../ranch.start_listener">ranch:start_listener(3)</a></p></div>
+</div>
+</div>
+ + + + + +</div> + +<div class="span3 sidecol"> + + +<h3> + Cowboy + 2.0 + Function Reference + +</h3> + +<ul> + + <li><a href="/docs/en/cowboy/2.0/guide">User Guide</a></li> + + + <li><a href="/docs/en/cowboy/2.0/manual">Function Reference</a></li> + + +</ul> + +<h4 id="docs-nav">Navigation</h4> + +<h4>Version select</h4> +<ul> + + + + <li><a href="/docs/en/cowboy/1.0/manual">1.0</a></li> + + <li><a href="/docs/en/cowboy/2.0/manual">2.0</a></li> + +</ul> + +</div> +</div> +</div> +</div> + + <footer> + <div class="container"> + <div class="row"> + <div class="span6"> + <p id="scroll-top"><a href="#">↑ Scroll to top</a></p> + <nav> + <ul> + <li><a href="mailto:[email protected]" title="Contact us">Contact us</a></li><li><a href="https://github.com/ninenines/ninenines.github.io" title="Github repository">Contribute to this site</a></li> + </ul> + </nav> + </div> + <div class="span6 credits"> + <p><img src="/img/footer_logo.png"></p> + <p>Copyright © Loïc Hoguin 2012-2016</p> + </div> + </div> + </div> + </footer> + + + <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script> + <script src="/js/bootstrap-carousel.js"></script> + <script src="/js/bootstrap-dropdown.js"></script> + <script src="/js/custom.js"></script> + </body> +</html> + + diff --git a/docs/en/cowboy/2.0/manual/cowboy/index.html b/docs/en/cowboy/2.0/manual/cowboy/index.html index 6763940e..19271913 100644 --- a/docs/en/cowboy/2.0/manual/cowboy/index.html +++ b/docs/en/cowboy/2.0/manual/cowboy/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: cowboy(3)</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -83,176 +83,116 @@ manipulating Ranch listeners.</p></div> </div>
</div>
<div class="sect1">
+<h2 id="_exports">Exports</h2>
+<div class="sectionbody">
+<div class="ulist"><ul>
+<li>
+<p>
+<a href="../cowboy.start_clear">cowboy:start_clear(3)</a> - Listen for connections using plain TCP
+</p>
+</li>
+<li>
+<p>
+<a href="../cowboy.start_tls">cowboy:start_tls(3)</a> - Listen for connections using TLS
+</p>
+</li>
+<li>
+<p>
+<a href="../cowboy.stop_listener">cowboy:stop_listener(3)</a> - Stop the given listener
+</p>
+</li>
+<li>
+<p>
+<a href="../cowboy.set_env">cowboy:set_env(3)</a> - Update a listener’s environment value
+</p>
+</li>
+</ul></div>
+</div>
+</div>
+<div class="sect1">
<h2 id="_types">Types</h2>
<div class="sectionbody">
<div class="sect2">
-<h3 id="_fields_field">fields() = [Field]</h3>
+<h3 id="_fields">fields()</h3>
<div class="listingblock">
<div class="content"><!-- Generator: GNU source-highlight 3.1.8
by Lorenzo Bettini
http://www.lorenzobettini.it
http://www.gnu.org/software/src-highlite -->
-<pre><tt><span style="color: #009900">Field</span> <span style="color: #990000">=</span> <span style="font-weight: bold"><span style="color: #000080">atom</span></span>()
- | {<span style="font-weight: bold"><span style="color: #000080">atom</span></span>(), <span style="font-weight: bold"><span style="color: #000000">cowboy_constraints:constraint</span></span>() | [<span style="font-weight: bold"><span style="color: #000000">cowboy_constraints:constraint</span></span>()]}
- | {<span style="font-weight: bold"><span style="color: #000080">atom</span></span>(), <span style="font-weight: bold"><span style="color: #000000">cowboy_constraints:constraint</span></span>() | [<span style="font-weight: bold"><span style="color: #000000">cowboy_constraints:constraint</span></span>()], <span style="font-weight: bold"><span style="color: #000000">any</span></span>()}]</tt></pre></div></div>
-<div class="paragraph"><p>Fields for match operations. Constraint(s) and default value are optional.</p></div>
+<pre><tt><span style="font-weight: bold"><span style="color: #000000">fields</span></span>() <span style="color: #990000">::</span> [<span style="color: #009900">Name</span>
+ | {<span style="color: #009900">Name</span>, <span style="color: #009900">Constraints</span>}
+ | {<span style="color: #009900">Name</span>, <span style="color: #009900">Constraints</span>, <span style="color: #009900">Default</span>}]
+
+<span style="color: #009900">Name</span> <span style="color: #990000">::</span> <span style="font-weight: bold"><span style="color: #000080">atom</span></span>()
+<span style="color: #009900">Constraints</span> <span style="color: #990000">::</span> <span style="color: #009900">Constraint</span> | [<span style="color: #009900">Constraint</span>]
+<span style="color: #009900">Constraint</span> <span style="color: #990000">::</span> <span style="font-weight: bold"><span style="color: #000000">cowboy_constraints:constraint</span></span>()
+<span style="color: #009900">Default</span> <span style="color: #990000">::</span> <span style="font-weight: bold"><span style="color: #000000">any</span></span>()</tt></pre></div></div>
+<div class="paragraph"><p>Fields description for match operations.</p></div>
+<div class="paragraph"><p>This type is used in <a href="../cowboy_router">cowboy_router</a>
+for matching bindings and in the match functions found in
+<a href="../cowboy_req">cowboy_req</a>.</p></div>
</div>
<div class="sect2">
-<h3 id="_http_headers_binary_iodata">http_headers() = [{binary(), iodata()}]</h3>
-<div class="paragraph"><p>HTTP headers as a list of key/values.</p></div>
+<h3 id="_http_headers">http_headers()</h3>
+<div class="listingblock">
+<div class="content"><!-- Generator: GNU source-highlight 3.1.8
+by Lorenzo Bettini
+http://www.lorenzobettini.it
+http://www.gnu.org/software/src-highlite -->
+<pre><tt><span style="font-weight: bold"><span style="color: #000000">http_headers</span></span>() <span style="color: #990000">::</span> #{<span style="font-weight: bold"><span style="color: #000080">binary</span></span>() <span style="color: #990000">=></span> <span style="font-weight: bold"><span style="color: #000000">iodata</span></span>()}</tt></pre></div></div>
+<div class="paragraph"><p>HTTP headers.</p></div>
</div>
<div class="sect2">
-<h3 id="_http_status_non_neg_integer_binary">http_status() = non_neg_integer() | binary()</h3>
-<div class="paragraph"><p>HTTP status.</p></div>
-<div class="paragraph"><p>A binary status can be used to set a custom message.</p></div>
+<h3 id="_http_status">http_status()</h3>
+<div class="listingblock">
+<div class="content"><!-- Generator: GNU source-highlight 3.1.8
+by Lorenzo Bettini
+http://www.lorenzobettini.it
+http://www.gnu.org/software/src-highlite -->
+<pre><tt><span style="font-weight: bold"><span style="color: #000000">http_status</span></span>() <span style="color: #990000">::</span> <span style="font-weight: bold"><span style="color: #000000">non_neg_integer</span></span>() | <span style="font-weight: bold"><span style="color: #000080">binary</span></span>()</tt></pre></div></div>
+<div class="paragraph"><p>HTTP response status.</p></div>
+<div class="paragraph"><p>A binary status can be used to set a reason phrase. Note
+however that HTTP/2 only sends the status code and drops
+the reason phrase entirely.</p></div>
</div>
<div class="sect2">
-<h3 id="_http_version_http_1_1_http_1_0">http_version() = 'HTTP/1.1' | 'HTTP/1.0'</h3>
+<h3 id="_http_version">http_version()</h3>
+<div class="listingblock">
+<div class="content"><!-- Generator: GNU source-highlight 3.1.8
+by Lorenzo Bettini
+http://www.lorenzobettini.it
+http://www.gnu.org/software/src-highlite -->
+<pre><tt><span style="font-weight: bold"><span style="color: #000000">http_version</span></span>() <span style="color: #990000">::</span> <span style="color: #FF6600">'HTTP/2'</span> | <span style="color: #FF6600">'HTTP/1.1'</span> | <span style="color: #FF6600">'HTTP/1.0'</span></tt></pre></div></div>
<div class="paragraph"><p>HTTP version.</p></div>
+<div class="paragraph"><p>Note that semantically, HTTP/1.1 and HTTP/2 are equivalent.</p></div>
</div>
<div class="sect2">
-<h3 id="_code_onresponse_fun_fun_http_status_http_headers_iodata_cowboy_req_req_gt_cowboy_req_req_code"><code>onresponse_fun() = fun((http_status(), http_headers(), iodata(), cowboy_req:req()) -> cowboy_req:req())</code></h3>
-<div class="paragraph"><p>Fun called immediately before sending the response.</p></div>
-<div class="paragraph"><p>It can perform any operation on the Req object, including
-reading the request body or replying. If a reply is sent, it
-overrides the reply initially sent. The callback will not be
-called again for the new reply.</p></div>
-</div>
-</div>
-</div>
-<div class="sect1">
-<h2 id="_exports">Exports</h2>
-<div class="sectionbody">
-<div class="sect2">
-<h3 id="_start_http_ref_nbacceptors_transopts_protoopts_8594_ok_pid">start_http(Ref, NbAcceptors, TransOpts, ProtoOpts) → {ok, pid()}</h3>
-<div class="dlist"><dl>
-<dt class="hdlist1">
-Ref = ranch:ref()
-</dt>
-<dd>
-<p>
-Listener name.
-</p>
-</dd>
-<dt class="hdlist1">
-NbAcceptors = non_neg_integer()
-</dt>
-<dd>
-<p>
-Number of acceptor processes.
-</p>
-</dd>
-<dt class="hdlist1">
-TransOpts = ranch_tcp:opts()
-</dt>
-<dd>
-<p>
-TCP transport options.
-</p>
-</dd>
-<dt class="hdlist1">
-ProtoOpts = cowboy_protocol:opts()
-</dt>
-<dd>
-<p>
-HTTP protocol options.
-</p>
-</dd>
-</dl></div>
-<div class="paragraph"><p>Start listening for HTTP connections. Returns the pid for this
-listener’s supervisor.</p></div>
-</div>
-<div class="sect2">
-<h3 id="_start_https_ref_nbacceptors_transopts_protoopts_8594_ok_pid">start_https(Ref, NbAcceptors, TransOpts, ProtoOpts) → {ok, pid()}</h3>
-<div class="dlist"><dl>
-<dt class="hdlist1">
-Ref = ranch:ref()
-</dt>
-<dd>
-<p>
-Listener name.
-</p>
-</dd>
-<dt class="hdlist1">
-NbAcceptors = non_neg_integer()
-</dt>
-<dd>
-<p>
-Number of acceptor processes.
-</p>
-</dd>
-<dt class="hdlist1">
-TransOpts = ranch_ssl:opts()
-</dt>
-<dd>
-<p>
-SSL transport options.
-</p>
-</dd>
-<dt class="hdlist1">
-ProtoOpts = cowboy_protocol:opts()
-</dt>
-<dd>
-<p>
-HTTP protocol options.
-</p>
-</dd>
-</dl></div>
-<div class="paragraph"><p>Start listening for HTTPS connections. Returns the pid for this
-listener’s supervisor.</p></div>
-</div>
-<div class="sect2">
-<h3 id="_stop_listener_ref_8594_ok_error_not_found">stop_listener(Ref) → ok | {error, not_found}</h3>
-<div class="dlist"><dl>
-<dt class="hdlist1">
-Ref = ranch:ref()
-</dt>
-<dd>
-<p>
-Listener name.
-</p>
-</dd>
-</dl></div>
-<div class="paragraph"><p>Stop a previously started listener.</p></div>
-</div>
-<div class="sect2">
-<h3 id="_set_env_ref_name_value_8594_ok">set_env(Ref, Name, Value) → ok</h3>
-<div class="dlist"><dl>
-<dt class="hdlist1">
-Ref = ranch:ref()
-</dt>
-<dd>
-<p>
-Listener name.
-</p>
-</dd>
-<dt class="hdlist1">
-Name = atom()
-</dt>
-<dd>
-<p>
-Name of environment value.
-</p>
-</dd>
-<dt class="hdlist1">
-Value = any()
-</dt>
-<dd>
-<p>
-Environment value.
-</p>
-</dd>
-</dl></div>
-<div class="paragraph"><p>Set or update an environment value for an already running listener.
-This will take effect on all subsequent connections.</p></div>
+<h3 id="_opts">opts()</h3>
+<div class="listingblock">
+<div class="content"><!-- Generator: GNU source-highlight 3.1.8
+by Lorenzo Bettini
+http://www.lorenzobettini.it
+http://www.gnu.org/software/src-highlite -->
+<pre><tt><span style="font-weight: bold"><span style="color: #000000">opts</span></span>() <span style="color: #990000">::</span> <span style="font-weight: bold"><span style="color: #000000">map</span></span>()</tt></pre></div></div>
+<div class="paragraph"><p>Options for the HTTP/1.1, HTTP/2 and Websocket protocols.</p></div>
+<div class="paragraph"><p>The protocol options are in a map containing all the options for
+the different protocols that may be involved when connecting
+to the listener, including HTTP/1.1 and HTTP/2 but also
+subprotocols like Websocket.</p></div>
+<div class="paragraph"><p>The HTTP/1.1 options are documented in the
+<a href="../cowboy_http">cowboy_http(3)</a> manual;
+the HTTP/2 options in
+<a href="../cowboy_http">cowboy_http2(3)</a>;
+and the Websocket options in
+<a href="../cowboy_websocket">cowboy_websocket(3)</a>.</p></div>
</div>
</div>
</div>
<div class="sect1">
<h2 id="_see_also">See also</h2>
<div class="sectionbody">
-<div class="paragraph"><p>The <a href="http://ninenines.eu/docs/en/ranch/HEAD/guide">Ranch guide</a>
-provides detailed information about how listeners work.</p></div>
+<div class="paragraph"><p><a href="../cowboy_app">cowboy(7)</a>,
+<a href="../ranch">ranch(3)</a></p></div>
</div>
</div>
diff --git a/docs/en/cowboy/2.0/manual/cowboy_app/index.html b/docs/en/cowboy/2.0/manual/cowboy_app/index.html index f8d0c139..a251adc8 100644 --- a/docs/en/cowboy/2.0/manual/cowboy_app/index.html +++ b/docs/en/cowboy/2.0/manual/cowboy_app/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: cowboy(7)</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -72,23 +72,152 @@ <div class="sect1">
<h2 id="_name">Name</h2>
<div class="sectionbody">
-<div class="paragraph"><p>cowboy - Small, fast, modular HTTP server.</p></div>
+<div class="paragraph"><p>cowboy - Small, fast, modern HTTP server for Erlang/OTP</p></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_description">Description</h2>
+<div class="sectionbody">
+<div class="paragraph"><p>Cowboy is an HTTP server for Erlang/OTP with support for the
+HTTP/1.1, HTTP/2 and Websocket protocols.</p></div>
+<div class="paragraph"><p>Cowboy aims to provide a complete HTTP stack. This includes
+the implementation of the HTTP RFCs but also any directly
+related standards, like Websocket or Server-Sent Events.</p></div>
+</div>
+</div>
+<div class="sect1">
+<h2 id="_modules">Modules</h2>
+<div class="sectionbody">
+<div class="paragraph"><p>Functions:</p></div>
+<div class="ulist"><ul>
+<li>
+<p>
+<a href="../cowboy">cowboy(3)</a> - Listener management
+</p>
+</li>
+<li>
+<p>
+<a href="../cowboy_req">cowboy_req(3)</a> - Request and response
+</p>
+</li>
+<li>
+<p>
+<a href="../cowboy_router">cowboy_router(3)</a> - Router
+</p>
+</li>
+</ul></div>
+<div class="paragraph"><p>Protocols:</p></div>
+<div class="ulist"><ul>
+<li>
+<p>
+<a href="../cowboy_http">cowboy_http(3)</a> - HTTP/1.1
+</p>
+</li>
+<li>
+<p>
+<a href="../cowboy_http">cowboy_http2(3)</a> - HTTP/2
+</p>
+</li>
+<li>
+<p>
+<a href="../cowboy_websocket">cowboy_websocket(3)</a> - Websocket
+</p>
+</li>
+</ul></div>
+<div class="paragraph"><p>Handlers:</p></div>
+<div class="ulist"><ul>
+<li>
+<p>
+<a href="../cowboy_static">cowboy_static(3)</a> - Static file handler
+</p>
+</li>
+</ul></div>
+<div class="paragraph"><p>Behaviors:</p></div>
+<div class="ulist"><ul>
+<li>
+<p>
+<a href="../cowboy_handler">cowboy_handler(3)</a> - Plain HTTP handlers
+</p>
+</li>
+<li>
+<p>
+<a href="../cowboy_loop">cowboy_loop(3)</a> - Loop handlers
+</p>
+</li>
+<li>
+<p>
+<a href="../cowboy_middleware">cowboy_middleware(3)</a> - Middlewares
+</p>
+</li>
+<li>
+<p>
+<a href="../cowboy_rest">cowboy_rest(3)</a> - REST handlers
+</p>
+</li>
+<li>
+<p>
+<a href="../cowboy_stream">cowboy_stream(3)</a> - Stream handlers
+</p>
+</li>
+<li>
+<p>
+<a href="../cowboy_sub_protocol">cowboy_sub_protocol(3)</a> - Sub protocols
+</p>
+</li>
+<li>
+<p>
+<a href="../cowboy_websocket">cowboy_websocket(3)</a> - Websocket handlers
+</p>
+</li>
+</ul></div>
+<div class="paragraph"><p>Middlewares:</p></div>
+<div class="ulist"><ul>
+<li>
+<p>
+<a href="../cowboy_router">cowboy_router(3)</a> - Router middleware
+</p>
+</li>
+<li>
+<p>
+<a href="../cowboy_handler">cowboy_handler(3)</a> - Handler middleware
+</p>
+</li>
+</ul></div>
</div>
</div>
<div class="sect1">
<h2 id="_dependencies">Dependencies</h2>
<div class="sectionbody">
-<div class="paragraph"><p>The <code>cowboy</code> application uses the Erlang applications <code>ranch</code>
-for listening and accepting TCP connections, <code>crypto</code> for
-establishing Websocket connections, and <code>cowlib</code> for parsing and
-building messages for Web protocols. These dependencies must
-be loaded for the <code>cowboy</code> application to work. In an embedded
-environment this means that they need to be started with the
-<code>application:start/{1,2}</code> function before the <code>cowboy</code>
-application is started.</p></div>
-<div class="paragraph"><p>The <code>cowboy</code> application also uses the Erlang applications
-<code>asn1</code>, <code>public_key</code> and <code>ssl</code> when listening for HTTPS connections.
-These are started automatically if they weren’t before.</p></div>
+<div class="ulist"><ul>
+<li>
+<p>
+<a href="../ranch">ranch(7)</a> - Socket acceptor pool for TCP protocols
+</p>
+</li>
+<li>
+<p>
+<a href="../cowlib">cowlib(7)</a> - Support library for manipulating Web protocols
+</p>
+</li>
+<li>
+<p>
+ssl - Secure communication over sockets
+</p>
+</li>
+<li>
+<p>
+crypto - Crypto functions
+</p>
+</li>
+</ul></div>
+<div class="paragraph"><p>All these applications must be started before the <code>cowboy</code>
+application. To start Cowboy and all dependencies at once:</p></div>
+<div class="listingblock">
+<div class="content"><!-- Generator: GNU source-highlight 3.1.8
+by Lorenzo Bettini
+http://www.lorenzobettini.it
+http://www.gnu.org/software/src-highlite -->
+<pre><tt>{<span style="color: #FF6600">ok</span>, <span style="color: #990000">_</span>} <span style="color: #990000">=</span> <span style="font-weight: bold"><span style="color: #000000">application:ensure_all_started</span></span>(<span style="color: #FF6600">cowboy</span>)<span style="color: #990000">.</span></tt></pre></div></div>
</div>
</div>
<div class="sect1">
@@ -98,6 +227,13 @@ These are started automatically if they weren’t before.</p></div> environment configuration parameters.</p></div>
</div>
</div>
+<div class="sect1">
+<h2 id="_see_also">See also</h2>
+<div class="sectionbody">
+<div class="paragraph"><p><a href="../ranch">ranch(7)</a>,
+<a href="../cowlib">cowlib(7)</a></p></div>
+</div>
+</div>
diff --git a/docs/en/cowboy/2.0/manual/cowboy_handler/index.html b/docs/en/cowboy/2.0/manual/cowboy_handler/index.html index 8130d474..ba64c876 100644 --- a/docs/en/cowboy/2.0/manual/cowboy_handler/index.html +++ b/docs/en/cowboy/2.0/manual/cowboy_handler/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: cowboy_handler(3)</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> diff --git a/docs/en/cowboy/2.0/manual/cowboy_loop/index.html b/docs/en/cowboy/2.0/manual/cowboy_loop/index.html index 70f6c9c1..df16397a 100644 --- a/docs/en/cowboy/2.0/manual/cowboy_loop/index.html +++ b/docs/en/cowboy/2.0/manual/cowboy_loop/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: cowboy_loop(3)</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> diff --git a/docs/en/cowboy/2.0/manual/cowboy_middleware/index.html b/docs/en/cowboy/2.0/manual/cowboy_middleware/index.html index acfcb743..20e6731c 100644 --- a/docs/en/cowboy/2.0/manual/cowboy_middleware/index.html +++ b/docs/en/cowboy/2.0/manual/cowboy_middleware/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: cowboy_middleware(3)</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> diff --git a/docs/en/cowboy/2.0/manual/cowboy_protocol/index.html b/docs/en/cowboy/2.0/manual/cowboy_protocol/index.html index de8730ae..bfe03a1f 100644 --- a/docs/en/cowboy/2.0/manual/cowboy_protocol/index.html +++ b/docs/en/cowboy/2.0/manual/cowboy_protocol/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: cowboy_protocol(3)</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> diff --git a/docs/en/cowboy/2.0/manual/cowboy_req/index.html b/docs/en/cowboy/2.0/manual/cowboy_req/index.html index bda581ba..d895d890 100644 --- a/docs/en/cowboy/2.0/manual/cowboy_req/index.html +++ b/docs/en/cowboy/2.0/manual/cowboy_req/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: cowboy_req(3)</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> diff --git a/docs/en/cowboy/2.0/manual/cowboy_rest/index.html b/docs/en/cowboy/2.0/manual/cowboy_rest/index.html index dcb46749..12ed4c05 100644 --- a/docs/en/cowboy/2.0/manual/cowboy_rest/index.html +++ b/docs/en/cowboy/2.0/manual/cowboy_rest/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: cowboy_rest(3)</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> diff --git a/docs/en/cowboy/2.0/manual/cowboy_router/index.html b/docs/en/cowboy/2.0/manual/cowboy_router/index.html index 45abf974..850d81a0 100644 --- a/docs/en/cowboy/2.0/manual/cowboy_router/index.html +++ b/docs/en/cowboy/2.0/manual/cowboy_router/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: cowboy_router(3)</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> diff --git a/docs/en/cowboy/2.0/manual/cowboy_static/index.html b/docs/en/cowboy/2.0/manual/cowboy_static/index.html index 9a4727e5..0b4ad099 100644 --- a/docs/en/cowboy/2.0/manual/cowboy_static/index.html +++ b/docs/en/cowboy/2.0/manual/cowboy_static/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: cowboy_static(3)</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> diff --git a/docs/en/cowboy/2.0/manual/cowboy_sub_protocol/index.html b/docs/en/cowboy/2.0/manual/cowboy_sub_protocol/index.html index 65397642..b897cac4 100644 --- a/docs/en/cowboy/2.0/manual/cowboy_sub_protocol/index.html +++ b/docs/en/cowboy/2.0/manual/cowboy_sub_protocol/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: cowboy_sub_protocol(3)</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> diff --git a/docs/en/cowboy/2.0/manual/cowboy_websocket/index.html b/docs/en/cowboy/2.0/manual/cowboy_websocket/index.html index d8cd3e46..5802a5d8 100644 --- a/docs/en/cowboy/2.0/manual/cowboy_websocket/index.html +++ b/docs/en/cowboy/2.0/manual/cowboy_websocket/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: cowboy_websocket(3)</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> diff --git a/docs/en/cowboy/2.0/manual/http_status_codes/index.html b/docs/en/cowboy/2.0/manual/http_status_codes/index.html index eaa74f9f..d2f7ac55 100644 --- a/docs/en/cowboy/2.0/manual/http_status_codes/index.html +++ b/docs/en/cowboy/2.0/manual/http_status_codes/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: HTTP status codes(7)</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> diff --git a/docs/en/cowboy/2.0/manual/index.html b/docs/en/cowboy/2.0/manual/index.html index 0fb488bf..e1b3dbe4 100644 --- a/docs/en/cowboy/2.0/manual/index.html +++ b/docs/en/cowboy/2.0/manual/index.html @@ -11,7 +11,7 @@ <title>Nine Nines: Cowboy Function Reference</title> - <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> + <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic' rel='stylesheet' type='text/css'> <link href="/css/bootstrap.min.css" rel="stylesheet"> <link href="/css/99s.css" rel="stylesheet"> @@ -117,11 +117,31 @@ </li>
<li>
<p>
+<a href="cowboy.set_env">cowboy:set_env(3)</a>
+</p>
+</li>
+<li>
+<p>
+<a href="cowboy.start_clear">cowboy:start_clear(3)</a>
+</p>
+</li>
+<li>
+<p>
+<a href="cowboy.start_tls">cowboy:start_tls(3)</a>
+</p>
+</li>
+<li>
+<p>
<a href="cowboy_static">cowboy_static(3)</a>
</p>
</li>
<li>
<p>
+<a href="cowboy.stop_listener">cowboy:stop_listener(3)</a>
+</p>
+</li>
+<li>
+<p>
<a href="cowboy_sub_protocol">cowboy_sub_protocol(3)</a>
</p>
</li>
diff --git a/docs/en/cowboy/HEAD/guide/index.html b/docs/en/cowboy/HEAD/guide/index.html index c1eedb2f..ea24e654 100644 --- a/docs/en/cowboy/HEAD/guide/index.html +++ b/docs/en/cowboy/HEAD/guide/index.html @@ -1 +1 @@ -<!DOCTYPE html><html><head><link rel="canonical" href="http://ninenines.eu/docs/"/><meta http-equiv="content-type" content="text/html; charset=utf-8" /><meta http-equiv="refresh" content="0;url=http://ninenines.eu/docs/" /></head></html>
\ No newline at end of file +<!DOCTYPE html><html><head><link rel="canonical" href="https://ninenines.eu/docs/"/><meta http-equiv="content-type" content="text/html; charset=utf-8" /><meta http-equiv="refresh" content="0;url=https://ninenines.eu/docs/" /></head></html>
\ No newline at end of file diff --git a/docs/en/cowboy/HEAD/index.html b/docs/en/cowboy/HEAD/index.html index c1eedb2f..ea24e654 100644 --- a/docs/en/cowboy/HEAD/index.html +++ b/docs/en/cowboy/HEAD/index.html @@ -1 +1 @@ -<!DOCTYPE html><html><head><link rel="canonical" href="http://ninenines.eu/docs/"/><meta http-equiv="content-type" content="text/html; charset=utf-8" /><meta http-equiv="refresh" content="0;url=http://ninenines.eu/docs/" /></head></html>
\ No newline at end of file +<!DOCTYPE html><html><head><link rel="canonical" href="https://ninenines.eu/docs/"/><meta http-equiv="content-type" content="text/html; charset=utf-8" /><meta http-equiv="refresh" content="0;url=https://ninenines.eu/docs/" /></head></html>
\ No newline at end of file diff --git a/docs/en/cowboy/HEAD/manual/index.html b/docs/en/cowboy/HEAD/manual/index.html index c1eedb2f..ea24e654 100644 --- a/docs/en/cowboy/HEAD/manual/index.html +++ b/docs/en/cowboy/HEAD/manual/index.html @@ -1 +1 @@ -<!DOCTYPE html><html><head><link rel="canonical" href="http://ninenines.eu/docs/"/><meta http-equiv="content-type" content="text/html; charset=utf-8" /><meta http-equiv="refresh" content="0;url=http://ninenines.eu/docs/" /></head></html>
\ No newline at end of file +<!DOCTYPE html><html><head><link rel="canonical" href="https://ninenines.eu/docs/"/><meta http-equiv="content-type" content="text/html; charset=utf-8" /><meta http-equiv="refresh" content="0;url=https://ninenines.eu/docs/" /></head></html>
\ No newline at end of file diff --git a/docs/en/cowboy/index.html b/docs/en/cowboy/index.html index c1eedb2f..ea24e654 100644 --- a/docs/en/cowboy/index.html +++ b/docs/en/cowboy/index.html @@ -1 +1 @@ -<!DOCTYPE html><html><head><link rel="canonical" href="http://ninenines.eu/docs/"/><meta http-equiv="content-type" content="text/html; charset=utf-8" /><meta http-equiv="refresh" content="0;url=http://ninenines.eu/docs/" /></head></html>
\ No newline at end of file +<!DOCTYPE html><html><head><link rel="canonical" href="https://ninenines.eu/docs/"/><meta http-equiv="content-type" content="text/html; charset=utf-8" /><meta http-equiv="refresh" content="0;url=https://ninenines.eu/docs/" /></head></html>
\ No newline at end of file |