The above config establishes a REST-capable listener listening on
localhost port 80. The "ACL" config option is set to internal
which can be used as a filter for ACL rules in the rest/acl config
section. The document_root is set, which will enable serving of
static files on URLs that do not otherwise match routing rules. The
ACL rule for internal set that all urls are allowed followed by a
blanket deny rule. Other listeners that might not specify an acl
option would not see the first ACL allowing any URL, but still see the
blanket deny rule.

Handling asynchronous work.

In order to complete some complex action in response to an inbound REST
request, it might be necessary to schedule some asynchronous work and
complete the response later. This is possible, but requires a bit of
juggling. The basic idea is:

Handling POST/PUT data

Reading data from the HTTP request is done by calling the
mtev_http_session_req_consume function. This can be tedious,
so unless you are doing something special it can be much easier
to simply first invoke the mtev_rest_complete_upload convenience
wrapper.

It must be called as the first action inside your REST callback handler.
Any manipulation of the restc (closures in particular) will have undefined
outcome.