Created
February 7, 2012 21:32
-
-
Save clows/1762137 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns ring-test.core | |
(:use ring.adapter.jetty) | |
(:use ring.middleware.multipart-params)) | |
(def data (atom [])) | |
(defn app [req] | |
wrap-multipart-params | |
(swap! data conj req) | |
{:status 200 | |
:headers { "Content-Type" "text/html"} | |
:body (str (slurp (:body req)))}) | |
(defonce server (run-jetty #'app {:port 8081 :join? false})) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment