From 2717428257e55871d29f84de0f55b59ac3122b24 Mon Sep 17 00:00:00 2001 From: Jeff White Date: Sun, 15 Apr 2018 12:16:49 -0700 Subject: fix typo --- docs/backends/custom.rst | 4 ++-- 1 file 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 `_ 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 `_ 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 `_ or `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 `_ or `OkHttp `_ (see the builder's ``retryOnConnectionFailure`` method). -- cgit v1.2.3