GcpCompute.Scheduling (GcpCompute v0.3.0)

Copy Markdown View Source

Parsed scheduling block of an instance.

Summary

Functions

Parse a decoded JSON scheduling map.

Types

t()

@type t() :: %GcpCompute.Scheduling{
  automatic_restart: boolean() | nil,
  instance_termination_action: String.t() | nil,
  max_run_duration: non_neg_integer() | nil,
  preemptible: boolean() | nil,
  provisioning_model: :spot | :standard | String.t() | nil,
  raw: map()
}

Functions

from_json(map)

@spec from_json(term()) :: t() | nil

Parse a decoded JSON scheduling map.

Total: nil or any non-map degrades to nil, and a "maxRunDuration" that is not the documented %{"seconds" => _} object degrades to nil rather than raising from get_in/2.