-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2dd9f98
commit bfcb94f
Showing
5 changed files
with
16 additions
and
20 deletions.
There are no files selected for viewing
Empty file.
Empty file.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{:cljdoc.doc/tree | ||
[["Overview" {:file "docs/01-overview.md"}] | ||
["Middleware" {:file "docs/02-middleware.md"}]]} |
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,23 @@ | ||
[![Build Status](https://travis-ci.com/rutledgepaulv/clj-okhttp.svg?branch=master)](https://travis-ci.com/rutledgepaulv/clj-okhttp) | ||
[![Clojars Project](https://img.shields.io/clojars/v/org.clojars.rutledgepaulv/clj-okhttp.svg)](https://clojars.org/org.clojars.rutledgepaulv/clj-okhttp) | ||
[![travisci](https://travis-ci.com/rutledgepaulv/clj-okhttp.svg?branch=master)](https://travis-ci.com/rutledgepaulv/clj-okhttp) | ||
[![clojars](https://img.shields.io/clojars/v/clj-okhttp/clj-okhttp.svg)](https://clojars.org/clj-okhttp) | ||
[![codecov](https://codecov.io/gh/rutledgepaulv/clj-okhttp/branch/master/graph/badge.svg)](https://codecov.io/gh/rutledgepaulv/clj-okhttp) | ||
[![cljdoc](https://cljdoc.org/badge/clj-okhttp/clj-okhttp)](https://cljdoc.org/d/clj-okhttp/clj-okhttp/CURRENT) | ||
|
||
### What | ||
|
||
A Clojure http and websocket client leveraging [OkHttp](https://github.com/square/okhttp), | ||
[Muuntaja](https://github.com/metosin/muuntaja), and [Jsonista](https://github.com/metosin/jsonista). | ||
Supports synchronous or asynchronous access patterns but does always use blocking io under the hood | ||
(per Square's implementation of OkHttp). | ||
A Clojure http and websocket client built on [OkHttp](https://github.com/square/okhttp), | ||
[Muuntaja](https://github.com/metosin/muuntaja), and [Jsonista](https://github.com/metosin/jsonista). Supports | ||
synchronous or asynchronous access patterns. | ||
|
||
Largely follows the style of other http libraries like clj-http but does not attempt to be a drop-in | ||
Largely follows the style of other http libraries like clj-http but does not attempt to be a perfect drop-in | ||
replacement. Supports per-client-instance and per-request middleware. | ||
|
||
### Why | ||
|
||
I have tried pretty much every http client in the Clojure ecosystem and couldn't find anything that satisfied everything | ||
I want. [hato](https://github.com/gnarroway/hato) comes pretty close but it's only Java 11+, uses cheshire, and I prefer | ||
a more explicit public API. I always had a pleasant experience with OkHttp in a past life when I mostly wrote Java. | ||
|
||
- Support for true raw response streaming. | ||
- Stop reading bytes from the server if I close the response stream before reading all content. | ||
- Support for websocket connections. | ||
- Support request/response encoding and decoding supporting json, edn, and transit. | ||
- Request encoding shouldn't retain lazy sequences. | ||
- Don't use exceptions for non-2xx status codes. | ||
- Simple connection pooling. | ||
- Lightweight dependencies. | ||
I want. [hato](https://github.com/gnarroway/hato) comes darn close but it's only Java 11+, uses cheshire, and I prefer a | ||
more explicit public API. I always had a pleasant experience with OkHttp in a past life when I primarily wrote Java. | ||
|
||
|
||
### [Documentation](https://cljdoc.org/d/org.clojars.rutledgepaulv/clj-okhttp/CURRENT) | ||
|