Skip to main content

Module pproxy_exec

Module pproxy_exec 

Source
Expand description

One shared pproxy compatibility execution pipeline.

The standalone pproxy binary and eggress pproxy run are alternate entry points to the same compatibility intent. This facade owns their common sequence — parse, strict validation, translation, execution gate, config compilation, --test diagnostics, daemon transition, and supervisor startup — so the two entry points cannot drift into different translation/gating/runtime behavior.

Process-specific rendering stays in the binaries, but only as a diag_prefix ("" for the nested command, "pproxy: " for the standalone binary) applied to facade-chosen messages. Business decisions (what fails, with which exit code, in which order) are returned as typed results. Do not force the standalone parser through the native Clap hierarchy; preserving pproxy argument behavior takes priority, so this facade consumes already-collected argv like both binaries always have.

Structs§

GatedRun
A compatibility invocation that passed parsing, strict validation, translation, and the fail-closed execution gate, but has not yet been compiled to a runtime configuration.
PrepareFailure
A fatal preparation failure: numeric exit code plus the unprefixed message. Binaries render it as {diag_prefix}error: {message}.
PreparedRun
A compatibility invocation that passed parsing, strict validation, translation, gating, and config compilation.

Enums§

PreparedAction
What a compatibility invocation should do after parsing.

Functions§

banner_lines
Structured startup-banner detail lines for the standalone binary.
compile
Compile a gated run’s translated TOML into a validated in-memory RuntimeConfig. No temporary file is created; the config lives entirely in process memory.
execute
Execute a prepared compatibility run: warnings, --test diagnostics, daemon transition, then the supervised service.
prepare
Run the shared preparation sequence over already-collected argv.