pub struct GraphConfig {
pub max_steps: u32,
pub debug: bool,
pub checkpoint_enabled: bool,
pub checkpoint_interval: u32,
pub timeout_ms: u64,
pub max_parallelism: usize,
pub custom: HashMap<String, Value>,
}Expand description
Graph execution configuration
Fields§
§max_steps: u32Maximum recursion depth
debug: boolEnable debug mode
checkpoint_enabled: boolEnable checkpointing
checkpoint_interval: u32Checkpoint interval (in steps)
timeout_ms: u64Timeout in milliseconds (0 = no timeout)
max_parallelism: usizeMaximum parallel branches
custom: HashMap<String, Value>Custom configuration values
Implementations§
Source§impl GraphConfig
impl GraphConfig
Sourcepub fn new() -> GraphConfig
pub fn new() -> GraphConfig
Create a new config with default values
Sourcepub fn with_max_steps(self, max_steps: u32) -> GraphConfig
pub fn with_max_steps(self, max_steps: u32) -> GraphConfig
Set maximum recursion depth
Sourcepub fn with_debug(self, debug: bool) -> GraphConfig
pub fn with_debug(self, debug: bool) -> GraphConfig
Enable debug mode
Sourcepub fn with_checkpoints(self, enabled: bool, interval: u32) -> GraphConfig
pub fn with_checkpoints(self, enabled: bool, interval: u32) -> GraphConfig
Enable checkpointing
Sourcepub fn with_timeout(self, timeout_ms: u64) -> GraphConfig
pub fn with_timeout(self, timeout_ms: u64) -> GraphConfig
Set timeout
Sourcepub fn with_max_parallelism(self, max: usize) -> GraphConfig
pub fn with_max_parallelism(self, max: usize) -> GraphConfig
Set maximum parallelism
Sourcepub fn with_custom(self, key: impl Into<String>, value: Value) -> GraphConfig
pub fn with_custom(self, key: impl Into<String>, value: Value) -> GraphConfig
Add a custom config value
Sourcepub fn remaining_steps(&self) -> RemainingSteps
pub fn remaining_steps(&self) -> RemainingSteps
Create RemainingSteps from this config
Trait Implementations§
Source§impl Clone for GraphConfig
impl Clone for GraphConfig
Source§fn clone(&self) -> GraphConfig
fn clone(&self) -> GraphConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for GraphConfig
impl Debug for GraphConfig
Source§impl Default for GraphConfig
impl Default for GraphConfig
Source§fn default() -> GraphConfig
fn default() -> GraphConfig
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for GraphConfig
impl<'de> Deserialize<'de> for GraphConfig
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<GraphConfig, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<GraphConfig, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for GraphConfig
impl Serialize for GraphConfig
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations§
impl Freeze for GraphConfig
impl RefUnwindSafe for GraphConfig
impl Send for GraphConfig
impl Sync for GraphConfig
impl Unpin for GraphConfig
impl UnsafeUnpin for GraphConfig
impl UnwindSafe for GraphConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Message for T
impl<T> Message for T
Source§fn from_boxed(m: BoxedMessage) -> Result<Self, BoxedDowncastErr>
fn from_boxed(m: BoxedMessage) -> Result<Self, BoxedDowncastErr>
Convert a BoxedMessage to this concrete type
Source§fn box_message(self, pid: &ActorId) -> Result<BoxedMessage, BoxedDowncastErr>
fn box_message(self, pid: &ActorId) -> Result<BoxedMessage, BoxedDowncastErr>
Convert this message to a BoxedMessage