Interface TimeoutAccess

  • All Superinterfaces:
    TimeoutAccess

    public interface TimeoutAccess
    extends TimeoutAccess
    Enables programmatic access to the server-side request timeout logic.

    Not for user extension.

    • Method Detail

      • getTimeout

        scala.concurrent.duration.Duration getTimeout()
        Java API
        Specified by:
        getTimeout in interface TimeoutAccess
      • timeout

        scala.concurrent.duration.Duration timeout()
        Returns the currently set timeout. The timeout period is measured as of the point in time that the end of the request has been received, which may be in the past or in the future!

        Due to the inherent raciness it is not guaranteed that the returned timeout was applied before the previously set timeout has expired!

        Returns:
        (undocumented)
      • update

        void update​(scala.concurrent.duration.Duration timeout,
                    scala.Function1<HttpRequest,​HttpResponse> handler)
        Tries to set a new timeout and handler at the same time.

        Due to the inherent raciness it is not guaranteed that the update will be applied before the previously set timeout has expired!

        Parameters:
        timeout - (undocumented)
        handler - (undocumented)
      • updateHandler

        void updateHandler​(scala.Function1<HttpRequest,​HttpResponse> handler)
        Tries to set a new timeout handler, which produces the timeout response for a given request. Note that the handler must produce the response synchronously and shouldn't block!

        Due to the inherent raciness it is not guaranteed that the update will be applied before the previously set timeout has expired!

        Parameters:
        handler - (undocumented)
      • updateTimeout

        void updateTimeout​(scala.concurrent.duration.Duration timeout)
        Tries to set a new timeout. The timeout period is measured as of the point in time that the end of the request has been received, which may be in the past or in the future! Use Duration.Inf to completely disable request timeout checking for this request.

        Due to the inherent raciness it is not guaranteed that the update will be applied before the previously set timeout has expired!

        Specified by:
        updateTimeout in interface TimeoutAccess
        Parameters:
        timeout - (undocumented)