Wednesday, May 27, 2009

Video Slideshow, Introducing Webmachine

The Webmachine talk at Bay Area Erlang Factory 2009 went quite well. I received useful feedback, and some very interesting and productive conversations spun off after the talk.

For anyone interested who wasn't there, I have recorded a voiceover with the slides and made that video available here. The slides are the same ones used at the conference, but I trimmed the speaking portion a bit. This version is a bit under half an hour; it leaves out a few minor topics but still covers all of the material needed to introduce Webmachine.

Per your presentation, it seems like webmachine is a great way to web-enable an existing IT capability. And in that respect I'm concerned that webmachine has significant dependencies - erlang and mochiweb. That's fine if your application is written in erlang, or if you are one-time integrating a legacy application into your environment, but not so good if you are shipping an integrated web-enabled capability that is not implemented in erlang.

How hard would it be to reimplement the core of webmachine in C? Are you aware of any similar projects implemented in C, kind of like the libevent http server but with all the expressive power of webmachine?

I don't think those dependencies are as significant as you think. Erlang, Mochiweb, and Webmachine work quite well and are very easy to install on most platforms. If you wanted to integrate with a C program, you could -- without too much difficulty -- wrote a C node using the "ei" library for erlang interface. That (or a similar bridging approach) is the path that I would generally recommend.

In terms of reimplementing the whole lot in C... well, of course it is possible but it'd be a pile of work. Webmachine is only about 3k lines of Erlang, but it relies heavily on the strengths of the Erlang language, the BEAM virtual machine, and the OTP libraries. That "expressive power" is a lot easier to produce in a more expressive language on a robust underlying platform. While you could write Webmachine in C, I am unconvinced that it would be worth the significant effort that it would take.