Tunnelling HTTP over a custom protocol in Clojure/Java -
i want tunnel http request stream on custom transport protocol. there clojure or, fallback, java http clients that'd let me access underlying request streams or lets me filter serialised requests , responses?
i know clj-http wraps apache httpcomponents, doesn't seem provide lot of hooks hc internals, , i've looked hc itself, have hard time navigating jungle of factories, interfaces , managers.
clj-http includes ability read , write input stream
(client/get "http://site.com/bigrequest.html" {:as :stream}) (client/post "http://site.com/resources" {:body (clojure.java.io/input-stream "/tmp/foo") :length 1000}) you can wrap stream in transport of choice.
Comments
Post a Comment