As a dominant web library in Clojure programming, Ring is a nice choice for beginners. First of all, its main function is to provide a convenient interface for a wide range of web-servers. From this point of view, the technology is extremely useful and works perfectly.
Another Ring feature is providing a set of modules ('middleware'
). So, it allows you to use different pre-written libraries, compatible with each other.
Most of Clojure programmers choose Ring for endpoints because of its ability to use middlewares. For instance, these modules allow transforming required parameters from an URL to the Clojure code map. A web developer can easily write new middleware and integrate it into the ecosystem. For example, using the cemerick/friend
library, you can fully manage the authorization process, apply different strategies (starting from the login and password, ending with oAuth
), etc. Ring middleware helps to conveniently describe and start the process. It closes all endpoints that are prohibited for unauthorized users.
Experience in using Ring is important for working with other Clojure technologies. It is the first thing you can use to get an app moving.