Closed aperiodic closed 11 years ago
Hello Dan,
Please point me to documentation that mentioned this example, since it is wrong in two places.
To fix it you need to:
So example should look like so:
(with-open [c1 (http/create-client :follow-redirects true)]
(http/await
(http/GET c1 "http://google.com")))
It is not very efficient to create client per each request, better would be to have client living longer that request.
Thank you for your feedback!
Augh, I skimmed right into the invocations in the detailed start section and didn't realize why await was important. My mistake. Thanks for the pointer!
Everything I try to request fails. I'm using version 0.5.0, and following the example usage from the docs:
This happens both from a swank server and a lein 2 repl. In both cases, the clj-http client works fine. This is using clojure 1.4.0 on OS X 10.6.8.