|
|
|
|
|
by noelwelsh
5317 days ago
|
|
Do you think the code is hard to read? BlueEyes is a framework for writing high performance web services. For it's use cases you care whether you're getting or putting. Thus it is explicit. Similarly, you care about performance, and so don't want to parse strings if you can help it -- thus you set the host once rather than parsing a URL. For a pure ease-of-use library Dispatch is probably the best, if you can figure out the syntax (see earlier discussion). In Dispatch you can write something like url("http://somesite.com/some/url") >>> System.out
I forget how you read into a string. Probably change >>> to >>@!#$$T%^@#$% or similar. |
|
Of course, more involved interactions require an API with more knobs. Clojure has a number of options, including touching the JDK's HTTP client API, or using a wrapper around something more grounded like clj-http[1] / Apache HTTPComponents.
[1] https://github.com/dakrone/clj-http