aboutsummaryrefslogtreecommitdiffstats
path: root/doc/src/manual/cowboy_router.asciidoc
diff options
context:
space:
mode:
authorLoïc Hoguin <[email protected]>2019-09-28 15:40:41 +0200
committerLoïc Hoguin <[email protected]>2019-09-28 15:40:41 +0200
commitcf84f59d9bdf819d943b3de8e3bc85c561f88efe (patch)
treeaa06efaba01ff939865797892c22f753b17ffe2d /doc/src/manual/cowboy_router.asciidoc
parent7bccad4d21b56837a1d9ded905b53800558ead8e (diff)
downloadcowboy-cf84f59d9bdf819d943b3de8e3bc85c561f88efe.tar.gz
cowboy-cf84f59d9bdf819d943b3de8e3bc85c561f88efe.tar.bz2
cowboy-cf84f59d9bdf819d943b3de8e3bc85c561f88efe.zip
Add persistent_term support to the router
Diffstat (limited to 'doc/src/manual/cowboy_router.asciidoc')
-rw-r--r--doc/src/manual/cowboy_router.asciidoc5
1 files changed, 4 insertions, 1 deletions
diff --git a/doc/src/manual/cowboy_router.asciidoc b/doc/src/manual/cowboy_router.asciidoc
index 61b8d57..d3c1306 100644
--- a/doc/src/manual/cowboy_router.asciidoc
+++ b/doc/src/manual/cowboy_router.asciidoc
@@ -13,7 +13,10 @@ The router takes the `dispatch` rules as input from the
middleware environment. Dispatch rules are generated by
calling the
link:man:cowboy_router:compile(3)[cowboy_router:compile(3)]
-function.
+function. The environment can contain the rules directly
+or a tuple `{persistent_term, Key}`, in which case Cowboy
+will call `persistent_term:get(Key)` to retrieve the
+dispatch rules.
When a route matches, the router sets the `handler` and
`handler_opts` middleware environment values containing