Skip to main content

RunContext

Resolves dependencies and references during MicroserviceModule::run_with_context.

pub fn use_relationship<T, S>(
&self,
relationship: &S,
) -> Result<T, MicroserviceError>
where
T: Clone + Send + Sync + 'static,
S: RunRelationship<T>

Pass either a Dependency<T> or Reference<T>. The returned value is owned, allowing it to move into the module's 'static run future.