aboutsummaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
authoradamw <adam@warski.org>2017-07-21 17:04:18 +0200
committeradamw <adam@warski.org>2017-07-21 17:04:18 +0200
commitec33423b3bc212292768c77c2a7a67715664f4e7 (patch)
tree3cdcd69bb81cc4a95706706367a446b3b4bc3ead /README.md
parente5ebd242a4cb982af6b01ec1976ecfc91398189f (diff)
downloadsttp-ec33423b3bc212292768c77c2a7a67715664f4e7.tar.gz
sttp-ec33423b3bc212292768c77c2a7a67715664f4e7.tar.bz2
sttp-ec33423b3bc212292768c77c2a7a67715664f4e7.zip
Monix handler
Diffstat (limited to 'README.md')
-rw-r--r--README.md14
1 files changed, 11 insertions, 3 deletions
diff --git a/README.md b/README.md
index b5b62e9..edd0705 100644
--- a/README.md
+++ b/README.md
@@ -243,16 +243,21 @@ To use, add the following dependency to your project:
"com.softwaremill.sttp" %% "async-http-client-handler-future" % version
// or
"com.softwaremill.sttp" %% "async-http-client-handler-scalaz" % version
+// or
+"com.softwaremill.sttp" %% "async-http-client-handler-monix" % version
```
This handler depends on [async-http-handler](https://github.com/AsyncHttpClient/async-http-client).
A fully **asynchronous** handler, which uses [Netty](http://netty.io) behind the
scenes.
-The responses are either wrapped in a `Future`, or a
-[Scalaz](https://github.com/scalaz/scalaz) `Task`, depending on the
-dependency chosen. In the latter case, there's an additional transitive
+The responses are wrapped depending on the dependency chosen in either a:
+
+* standard Scala `Future`
+* [Scalaz](https://github.com/scalaz/scalaz) `Task`. There's a transitive
dependency on `scalaz-concurrent`.
+* [Monix](https://monix.io) `Task`. There's a transitive dependency on
+`monix-eval`.
Next you'll need to add an implicit value:
@@ -262,6 +267,9 @@ implicit val sttpHandler = new FutureAsyncHttpClientHandler()
// or, if you're using the scalaz version:
implicit val sttpHandler = new ScalazAsyncHttpClientHandler()
+// or, if you're using the monix version:
+implicit val sttpHandler = new MonixAsyncHttpClientHandler()
+
// or, if you'd like to use custom configuration:
implicit val sttpHandler = new FutureAsyncHttpClientHandler(asyncHttpClientConfig)