#[non_exhaustive]pub struct ExecutionContext {
pub input_payload: Vec<u8>,
pub execution_kind: String,
pub tags: HashMap<String, String>,
}Expand description
Point-read bundle of the three execution-scoped fields the SDK
worker needs to construct a ClaimedTask (see ff_sdk::ClaimedTask):
input_payload, execution_kind, and tags.
Returned by
EngineBackend::read_execution_context.
All three fields are execution-scoped (not per-attempt) across
Valkey, Postgres, and SQLite — there is no per-attempt variant in
the data model.
#[non_exhaustive] — FF may add fields in minor releases without a
semver break. Construct via ExecutionContext::new; match with
.. when destructuring.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.input_payload: Vec<u8>Opaque payload handed to the execution body. Empty when the execution was created with no payload.
execution_kind: StringCaller-supplied execution_kind label — free-form string
identifying which handler the worker should dispatch to.
Caller-owned tag map. Tag key conventions mirror
ExecutionSnapshot::tags; empty when no tags are set.
Implementations§
Source§impl ExecutionContext
impl ExecutionContext
Sourcepub fn new(
input_payload: Vec<u8>,
execution_kind: String,
tags: HashMap<String, String>,
) -> Self
pub fn new( input_payload: Vec<u8>, execution_kind: String, tags: HashMap<String, String>, ) -> Self
Construct an ExecutionContext. Present so downstream crates
(concrete EngineBackend impls) can assemble the struct despite
the #[non_exhaustive] marker. Prefer adding builder-style
helpers here over loosening non_exhaustive.
Trait Implementations§
Source§impl Clone for ExecutionContext
impl Clone for ExecutionContext
Source§fn clone(&self) -> ExecutionContext
fn clone(&self) -> ExecutionContext
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more