diff options
author | Loïc Hoguin <[email protected]> | 2017-06-09 11:44:12 +0200 |
---|---|---|
committer | Loïc Hoguin <[email protected]> | 2017-06-09 11:44:12 +0200 |
commit | f3ab9ef65d948469e864184bcf95114bf8025ad1 (patch) | |
tree | 77458e2ece4e95d5e16ae7466ef22750c0edc9ac /docs/en/cowboy/2.0/manual/cowboy_websocket | |
parent | 5a0feb20ace7a923b1101c274ef2ff12fa47a776 (diff) | |
download | ninenines.eu-f3ab9ef65d948469e864184bcf95114bf8025ad1.tar.gz ninenines.eu-f3ab9ef65d948469e864184bcf95114bf8025ad1.tar.bz2 ninenines.eu-f3ab9ef65d948469e864184bcf95114bf8025ad1.zip |
Release the tale of 2.0 cowboy slides
Diffstat (limited to 'docs/en/cowboy/2.0/manual/cowboy_websocket')
-rw-r--r-- | docs/en/cowboy/2.0/manual/cowboy_websocket/index.html | 15 |
1 files changed, 14 insertions, 1 deletions
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 9647657b..f09890a8 100644 --- a/docs/en/cowboy/2.0/manual/cowboy_websocket/index.html +++ b/docs/en/cowboy/2.0/manual/cowboy_websocket/index.html @@ -255,7 +255,8 @@ 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="color: #0000FF">compress</span> <span style="color: #990000">=></span> <span style="font-weight: bold"><span style="color: #000000">boolean</span></span>(),
- <span style="color: #0000FF">idle_timeout</span> <span style="color: #990000">=></span> <span style="font-weight: bold"><span style="color: #000000">timeout</span></span>()
+ <span style="color: #0000FF">idle_timeout</span> <span style="color: #990000">=></span> <span style="font-weight: bold"><span style="color: #000000">timeout</span></span>(),
+ <span style="color: #0000FF">req_filter</span> <span style="color: #990000">=></span> <span style="font-weight: bold"><span style="color: #0000FF">fun</span></span>((<span style="font-weight: bold"><span style="color: #000000">cowboy_req:req</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>Websocket handler options.</p></div>
<div class="paragraph"><p>This configuration is passed to Cowboy from the <code>init/2</code>
@@ -290,6 +291,18 @@ idle_timeout (60000) the client.
</p>
</dd>
+<dt class="hdlist1">
+req_filter
+</dt>
+<dd>
+<p>
+ A function applied to the Req to compact it and
+ only keep required information. The Req is only
+ given back in the <code>terminate/3</code> callback. By default
+ it keeps the method, version, URI components and peer
+ information.
+</p>
+</dd>
</dl></div>
</div>
</div>
|