View Source K8s.Client.Runner.Stream (k8s v1.1.1)

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

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

Specs

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

Halt streaming

Specs

List of items and pagination request

Link to this section Functions

Link to this function

run(conn, op, http_opts \\ [])

View Source

Specs

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

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

Link to this function

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

View Source

Specs

stream(K8s.Conn.t(), K8s.Operation.t(), 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.