Tesla.Middleware.Timeout (tesla v1.4.0) View Source

Timeout http request after X milliseconds.

Example

defmodule MyClient do
  use Tesla

  plug Tesla.Middleware.Timeout, timeout: 2_000
end

Options

  • :timeout - number of milliseconds a request is allowed to take (defaults to 1000)