morca · API

orca.config_show

orca config show and orca config export (orca.config): each pipeline's settings with where each came from, as text, HTML and JSON, and the registered settings written back as an orca.toml.

Structs

Shown

struct Shown

One registered pipeline's effective configuration.

Implements Movable

Fields
name: String
file: String
hash: String
commit: String
dirty: Bool
source: String
repo_path: String: The file's path in its checkout, for links to its lines.
overrides: List[Tuple[String, String]]
rows: List[_Row]
learned: Optional[Recommendation]: The request its runs' peaks suggest (orca.recommend), applied when it asks for auto and learns.
auto: Bool: Whether its cpus or memory_gb is auto.
learn: Bool: Whether it learns (learn, true unless set false).

__init__

def __init__(out self, name: String)

add

def add(mut self, key: String, value: String, source: String, detail: String)

applied_text

def applied_text(self) -> String

Whether its runs start with what it learned, and why not.

json

def json(self) -> String

text

def text(self) -> String

Functions

config_html

def config_html(mut h: Html, s: Shown, repo: String = "", code_line: String = "")

The pipeline page's Configuration (id="config"): what orca config show prints, where it was registered from, and the flags that overrode the file. Each key has its help, each value from a fixed set its meaning on hover, and From links to where the value is set where that's known: an orca.toml line at the registration's commit in repo (a repository's web address), or for a default from the pipeline's code, code_line, its declaration.

shown

def shown(mut db: State, only: String = "") -> List[Shown]

The effective configuration of each registered pipeline (or the one named), with the source of every value. Values orca's runners take from their environment when nothing is registered (ORCA_EC2_HEAD_TYPE, ORCA_EC2_WORKER_TYPE, ORCA_RUN_ENV's variables) are read from this process's, which is the scheduler's when run beside it.

show_json

def show_json(items: List[Shown], one: Bool) -> String

orca config show --json: the pipeline's object, or for all of them {"pipelines": [...]}.

export_toml

def export_toml(mut db: State) -> String

orca config export: an orca.toml with a [pipelines.<name>] for each registered pipeline holding what's registered for it beyond the defaults, which registering from it again gives back.