dwwoelfel.talaria

https://github.com/dwwoelfel/talaria.git

git clone 'https://github.com/dwwoelfel/talaria.git'

(ql:quickload :dwwoelfel.talaria)
44

Talaria

Talaria is a simple Clojure library that handles client-server communication for real-time web applications.

Talaria provides bi-directional communication over websockets with fallback to Ajax long-polling.

It's running in production at Precursor, a collaborative prototyping app.

Why build a new thing?

Precursor required a few features that weren't available in other libraries:

  1. on-complete callbacks for messages sent from the server

These are handy for exerting backpressure and for dropping unnecessary messages (e.g. sharing mouse positions between clients–only the last mouse position matters).

  1. Long-polling fallback for clients with browsers that support websockets, but networks that don't (e.g. firewall rules that terminate connections)

  2. Direct access to underlying channels

  3. Easy instrumentation

Requirements

Talaria currently requires Immutant as the web server. It should be possible to use Aleph as the server. If you're familiar with Aleph and want to see support for it, please email dwwoelfel@gmail.com. Unfortunately, http-kit is out until it gets support for notifications when messages are received by the client.

Expects ring session middleware to be present.

TODO

License

Copyright © 2015 FIXME

Distributed under the Eclipse Public License either version 1.0 or (at your option) any later version.