pub struct RouteIdentityStep {
pub name: String,
pub config_override: Option<Value>,
pub on_error: Option<String>,
pub extra: HashMap<String, Value>,
}Expand description
One step in the identity-phase pipeline. Points at a plugin
registered under the identity.resolve hook, optionally with
a per-call config override and an on_error policy that
controls what happens when the step fails.
§Cumulative stacking
At runtime, every step in the block runs (subject to its own
on_error). Each step’s resolved IdentityPayload accumulates
— handlers contribute orthogonal slots (JWT → subject;
SPIFFE → caller_workload; agent resolver → agent) so they
compose without collision in the common case.
§On-error semantics
NoneorSome("continue")— soft failure: the step’s contribution is dropped, the next step runs, and any missing extensions get caught later byrequire(authenticated)/require(workload.*)in downstream policy.Some("deny")— hard requirement: a failure halts the request with the plugin’s violation code.
Unknown strings parse as best-effort; future slices may introduce typed enums.
§Per-step config override
config_override reuses the existing per-call override
pathway. When present, the framework’s
create_override_instance builds a new plugin instance with
the merged config and dispatches into it for this route.
Fields§
§name: StringPlugin name — must match an entry in the top-level
plugins: block that registers under identity.resolve.
config_override: Option<Value>Optional config override applied for this step only.
None means “use the plugin’s configured defaults from the
plugins: declaration.” Stored as serde_json::Value to
match the existing create_override_instance interface.
on_error: Option<String>Per-step failure handling. See type-level docs.
extra: HashMap<String, Value>Catch-all for any other fields a future schema version adds (timeout, priority, condition, …) — preserved so the parser doesn’t reject configs targeting newer runtimes.
Implementations§
Trait Implementations§
Source§impl Clone for RouteIdentityStep
impl Clone for RouteIdentityStep
Source§fn clone(&self) -> RouteIdentityStep
fn clone(&self) -> RouteIdentityStep
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more