Skip to content
This repository has been archived by the owner on Dec 11, 2018. It is now read-only.

Commit

Permalink
Add dispatch options documentation to the README
Browse files Browse the repository at this point in the history
  • Loading branch information
Loïc Hoguin committed Jan 9, 2012
1 parent a76c29a commit 64fcd99
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions README.md
Expand Up @@ -15,6 +15,24 @@ provides an optional heartbeat which is managed on the client side.

Today Bullet only supports websocket and long-polling transports.

Dispatch options
----------------

Similar to any other handler, you need to setup the dispatch list before
you can access your Bullet handlers. Bullet itself is a Cowboy HTTP
handler that translates some of the lower-level functions into a
simplified higher-level interface.

The dispatch options for a Bullet handler looks as follow:

``` erlang
{[<<"path">>, <<"to">>, <<"bullet">>], bullet_handler,
[{handler, my_stream}]}
```

Simply define this in your dispatch list and your handler will be
available and handled by Bullet properly.

Cowboy handler
--------------

Expand Down

0 comments on commit 64fcd99

Please sign in to comment.