Fil.UnavailableError exception (Fil v0.5.1)

Copy Markdown View Source

The storage didn't answer, or asked to wait. Try again later.

Adapters return it for a timeout, a closed connection, a server error, throttling and too many open files. A stream from S3 or Azure Blob that isn't read for :stream_idle_timeout raises it with reason: :idle_timeout, because it gave its connection back to the pool. It's one of the two errors where retrying may help, with Fil.ConflictError. Fil doesn't retry (for now), because only the caller knows whether a failed mutation is safe to repeat. The one exception is a part of an S3 upload in parts, which is sent once more, a second later: nobody sees it before the upload completes.

Summary

Types

t()

@type t() :: %Fil.UnavailableError{
  __exception__: term(),
  disk: Fil.Disk.t() | nil,
  op: Fil.Op.name() | nil,
  path: String.t() | nil,
  reason: term()
}