I have been working on creating an interface to ZeroMQ and Mongrel2 in Julia. The code is here:
https://github.com/aviks/julia-zmq-mongrel ... I doubt this should go into the standard library at this stage, hence a separate repo.
ZeroMQ is a networking library provides what looks like a simple socket interface, but implements a series of higher order network functions over it. For example, you get pub/sub or request/response primitives built in, and it handles connections and reconnects automatically.
Mongrel2 is a language agnostic web server, built on ZMQ, that allows one to easily write web service handlers in any supported language. You can therefore write a handler for a web request in a couple of lines of julia, and get a production quality web server to host it. You also get, for free, the ability to run a cluster of such handlers fronted by a single mongrel instance.
I realise the web repl is done with an SCGI wrapper, but having never run scgi without problems in the past, I wanted a second path to the web for Julia code :). Eventually, I imagine someone will do a mod_julia for apache, and there'll be a full web server written in Julia itself (there's an effort at
https://github.com/chzyer/JuliaWebServer I saw), but for the moment mongrel will provide a robust production quality web server for julia code.
I'd appreciate any feedback on this.
Regards
-
Avik