Export to
Tuesday, February 18, 2014 at 10:05am.
Kevin Lynagh: Walkthrough of a Clojure+Clojurescript+Datomic Image Diffing Application
Puppet Labs is hosting! Come by and enjoy their hospitality.
Website
Description
Kevin sez:
The domain problem is conceptually simple: you provide sets of images and are notified with visual diffs of changes. The motivating use case was regression testing a web data visualization product---taking screenshots is far easier and more comprehensive than unit testing JavaScript + DOM + CSS styling.
The application is about 1300 lines of code, which includes all of the (Clojure-generated) markup and styling.It's built with Clojure, ClojureScript, and Datomic. I'll touch on:
designing an application around Stuart Sierra's "Reloaded" workflow: http://thinkrelevance.com/blog/2013/06/04/clojure-workflow-reloaded
basics (and not-so-basics) of the Ring HTTP model
using Chas Emerick's Friend library to handle web user and API authentication
deploying/monitoring a Clojure application in (low-stakes) production
structuring an application around protocols so that service backends (e.g., S3) can be easily swapped between development, staging, and production
If there's anything that seems particularly interesting to you (in the above list or otherwise), please reply to this thread so I can prepare a bit of material.
I'm planning on giving a 20 minute high-level overview of the application, and then opening it up to questions and focussing on whatever topics folks are interested in.