k8s v0.5.2 K8s.Client.Runner.Stream

Takes a K8s.Client.list/3 operation and returns an Elixir Stream

Link to this section Summary

Types

Halt streaming

List of items and pagination request

Functions

Validates operation type before calling stream/3. Only supports verbs: list_all_namespaces and list.

Returns an elixir stream of paginated list results.

Link to this section Types

Link to this type

halt_t()

halt_t() :: {:halt, state_t()}

Halt streaming

List of items and pagination request

Link to this section Functions

Link to this function

run(operation, conn, opts \\ [])

run(K8s.Operation.t(), K8s.Conn.t(), keyword()) ::
  {:ok, Enumerable.t()} | {:error, atom()}

Validates operation type before calling stream/3. Only supports verbs: list_all_namespaces and list.

Link to this function

stream(op, conn, opts \\ [])

stream(K8s.Operation.t(), atom(), keyword() | nil) :: Enumerable.t()

Returns an elixir stream of paginated list results.

Elements in stream will be HTTP bodies, or error tuples.

Encountering an HTTP error mid-stream will halt the stream.