aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeff White <jsw@liquidchill.org>2018-04-15 12:16:49 -0700
committerGitHub <noreply@github.com>2018-04-15 12:16:49 -0700
commit2717428257e55871d29f84de0f55b59ac3122b24 (patch)
tree81af2bcdf6fb8eaa321b736b3096cfd036ea6f56
parent778ff9f48cd6dcc1c22aa00d2372aec1074c89aa (diff)
downloadsttp-2717428257e55871d29f84de0f55b59ac3122b24.tar.gz
sttp-2717428257e55871d29f84de0f55b59ac3122b24.tar.bz2
sttp-2717428257e55871d29f84de0f55b59ac3122b24.zip
fix typo
-rw-r--r--docs/backends/custom.rst4
1 files changed, 2 insertions, 2 deletions
diff --git a/docs/backends/custom.rst b/docs/backends/custom.rst
index cca6a72..17571e1 100644
--- a/docs/backends/custom.rst
+++ b/docs/backends/custom.rst
@@ -102,7 +102,7 @@ Handling retries is a complex problem when it comes to HTTP requests. When is a
* only idempotent HTTP methods (such as ``GET``) could potentially be retried
* some HTTP status codes might also be retryable (e.g. ``500 Internal Server Error`` or ``503 Service Unavailable``)
-In some cases it's possible to implement a generic retry mechanism; such a mechanism should take into account logging, metrics, limiting the number of retries and a backoff mechanism. These mechanisms could be quite simple, or involve e.g. retry budges (see `Finagle's <https://twitter.github.io/finagle/guide/Clients.html#retries>`_ documentation on retries). In sttp, it's possible to recover from errors using the ``responseMonad``. A starting point for a retrying backend could be::
+In some cases it's possible to implement a generic retry mechanism; such a mechanism should take into account logging, metrics, limiting the number of retries and a backoff mechanism. These mechanisms could be quite simple, or involve e.g. retry budgets (see `Finagle's <https://twitter.github.io/finagle/guide/Clients.html#retries>`_ documentation on retries). In sttp, it's possible to recover from errors using the ``responseMonad``. A starting point for a retrying backend could be::
import com.softwaremill.sttp.{MonadError, Request, Response, SttpBackend}
@@ -137,4 +137,4 @@ In some cases it's possible to implement a generic retry mechanism; such a mecha
override def responseMonad: MonadError[R] = delegate.responseMonad
}
-Note that some backends also have built-in retry mechanisms, e.g. `akka-http <https://doc.akka.io/docs/akka-http/current/scala/http/client-side/host-level.html#retrying-a-request>`_ or `OkHttp <http://square.github.io/okhttp>`_ (see the builder's ``retryOnConnectionFailure`` method). \ No newline at end of file
+Note that some backends also have built-in retry mechanisms, e.g. `akka-http <https://doc.akka.io/docs/akka-http/current/scala/http/client-side/host-level.html#retrying-a-request>`_ or `OkHttp <http://square.github.io/okhttp>`_ (see the builder's ``retryOnConnectionFailure`` method).