From c81487ff2c6d0a4a886ac9ceb7a7a89a39eb5c88 Mon Sep 17 00:00:00 2001 From: adamw Date: Thu, 3 Aug 2017 20:51:45 +0200 Subject: Custom backends readme --- README.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/README.md b/README.md index 9721bed..25f51d4 100644 --- a/README.md +++ b/README.md @@ -356,6 +356,16 @@ both a **synchronous** (`OkHttpSyncClientHandler`) and **asynchronous** OkHttp fully supports HTTP/2. +### Custom backends, logging, metrics + +It is also entirely possible to write your own backend (if so, please consider +contributing!) or wrapping an existing one. You can even write completely +generic wrappers for any delegate backend, as the each backend comes equipped +with a monad for the response wrapper. + +This brings the possibility to `map` and `flatMap` over responses. That way you +could implement e.g. a logging or metric-capturing wrapper. + ## Request type All request descriptions have type `RequestT[U, T, S]` (T as in Template). -- cgit v1.2.3