pub struct SiteWorkflows { /* private fields */ }Expand description
The executor of the site’s model-free jobs, one probe and one digest per site (spec 3.5 §7.20).
Implementations§
Source§impl SiteWorkflows
impl SiteWorkflows
Sourcepub fn probe(self, site: Uuid, probe: Arc<GuardianProbe>) -> Self
pub fn probe(self, site: Uuid, probe: Arc<GuardianProbe>) -> Self
Runs site’s probe.
Sourcepub fn watch(self, site: Uuid, check: Arc<UpkeepCheck>) -> Self
pub fn watch(self, site: Uuid, check: Arc<UpkeepCheck>) -> Self
Runs site’s daily upkeep check (spec 3.5 §7.20).
Sourcepub fn repository(self, site: Uuid, entry: Arc<RepositoryEntry>) -> Self
pub fn repository(self, site: Uuid, entry: Arc<RepositoryEntry>) -> Self
Takes site’s pushes to its content repository (spec 3.5 §7.8.2).
Sourcepub fn learning(self, site: Uuid, learning: Arc<PlaybookLearning>) -> Self
pub fn learning(self, site: Uuid, learning: Arc<PlaybookLearning>) -> Self
Runs site’s weekly playbook learning (spec 3.5 §7.15).
Sourcepub fn digest(self, site: Uuid, target: DigestTarget) -> Self
pub fn digest(self, site: Uuid, target: DigestTarget) -> Self
Sends site’s weekly review to target.
Trait Implementations§
Source§impl Default for SiteWorkflows
impl Default for SiteWorkflows
Source§impl WorkflowExecutor for SiteWorkflows
impl WorkflowExecutor for SiteWorkflows
Source§fn has_workflow(&self, workflow_id: &str) -> bool
fn has_workflow(&self, workflow_id: &str) -> bool
Whether
workflow_id can be executed. Read moreSource§fn execute<'life0, 'life1, 'async_trait>(
&'life0 self,
workflow_id: &'life1 str,
input: WorkflowState,
cancel_token: CancellationToken,
) -> Pin<Box<dyn Future<Output = Result<Value, String>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn execute<'life0, 'life1, 'async_trait>(
&'life0 self,
workflow_id: &'life1 str,
input: WorkflowState,
cancel_token: CancellationToken,
) -> Pin<Box<dyn Future<Output = Result<Value, String>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Source§fn execute_durable<'life0, 'life1, 'async_trait>(
&'life0 self,
workflow_id: &'life1 str,
input: HashMap<String, Value>,
run: WorkflowRunContext,
) -> Pin<Box<dyn Future<Output = Result<Value, String>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
fn execute_durable<'life0, 'life1, 'async_trait>(
&'life0 self,
workflow_id: &'life1 str,
input: HashMap<String, Value>,
run: WorkflowRunContext,
) -> Pin<Box<dyn Future<Output = Result<Value, String>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
Run
workflow_id as one attempt of a durable run. Read moreAuto Trait Implementations§
impl !RefUnwindSafe for SiteWorkflows
impl !UnwindSafe for SiteWorkflows
impl Forget for SiteWorkflows
impl Freeze for SiteWorkflowswhere
*const LeafNode<Uuid, Arc<GuardianProbe>> is !null: Freeze,
PhantomData<(Owned, LeafOrInternal)>: Freeze,
PhantomData<Box<(Uuid, Arc<GuardianProbe>)>>: Freeze,
*const LeafNode<Uuid, Arc<UpkeepCheck>> is !null: Freeze,
PhantomData<Box<(Uuid, Arc<UpkeepCheck>)>>: Freeze,
*const LeafNode<Uuid, DigestTarget> is !null: Freeze,
PhantomData<Box<(Uuid, DigestTarget)>>: Freeze,
*const LeafNode<Uuid, Arc<RepositoryEntry>> is !null: Freeze,
PhantomData<Box<(Uuid, Arc<RepositoryEntry>)>>: Freeze,
*const LeafNode<Uuid, Arc<PlaybookLearning>> is !null: Freeze,
PhantomData<Box<(Uuid, Arc<PlaybookLearning>)>>: Freeze,
impl Move for SiteWorkflows
impl Send for SiteWorkflowswhere
NodeRef<Owned, Uuid, Arc<GuardianProbe>, LeafOrInternal>: Send,
BoxRaw<(Uuid, Arc<GuardianProbe>)>: Send,
NodeRef<Owned, Uuid, Arc<UpkeepCheck>, LeafOrInternal>: Send,
BoxRaw<(Uuid, Arc<UpkeepCheck>)>: Send,
NodeRef<Owned, Uuid, DigestTarget, LeafOrInternal>: Send,
BoxRaw<(Uuid, DigestTarget)>: Send,
NodeRef<Owned, Uuid, Arc<RepositoryEntry>, LeafOrInternal>: Send,
BoxRaw<(Uuid, Arc<RepositoryEntry>)>: Send,
NodeRef<Owned, Uuid, Arc<PlaybookLearning>, LeafOrInternal>: Send,
BoxRaw<(Uuid, Arc<PlaybookLearning>)>: Send,
impl Sync for SiteWorkflowswhere
NodeRef<Owned, Uuid, Arc<GuardianProbe>, LeafOrInternal>: Sync,
BoxRaw<(Uuid, Arc<GuardianProbe>)>: Sync,
NodeRef<Owned, Uuid, Arc<UpkeepCheck>, LeafOrInternal>: Sync,
BoxRaw<(Uuid, Arc<UpkeepCheck>)>: Sync,
NodeRef<Owned, Uuid, DigestTarget, LeafOrInternal>: Sync,
BoxRaw<(Uuid, DigestTarget)>: Sync,
NodeRef<Owned, Uuid, Arc<RepositoryEntry>, LeafOrInternal>: Sync,
BoxRaw<(Uuid, Arc<RepositoryEntry>)>: Sync,
NodeRef<Owned, Uuid, Arc<PlaybookLearning>, LeafOrInternal>: Sync,
BoxRaw<(Uuid, Arc<PlaybookLearning>)>: Sync,
impl Unpin for SiteWorkflowswhere
*const LeafNode<Uuid, Arc<GuardianProbe>> is !null: Unpin,
Box<(Uuid, Arc<GuardianProbe>)>: Unpin,
*const LeafNode<Uuid, Arc<UpkeepCheck>> is !null: Unpin,
Box<(Uuid, Arc<UpkeepCheck>)>: Unpin,
*const LeafNode<Uuid, DigestTarget> is !null: Unpin,
Box<(Uuid, DigestTarget)>: Unpin,
*const LeafNode<Uuid, Arc<RepositoryEntry>> is !null: Unpin,
Box<(Uuid, Arc<RepositoryEntry>)>: Unpin,
*const LeafNode<Uuid, Arc<PlaybookLearning>> is !null: Unpin,
Box<(Uuid, Arc<PlaybookLearning>)>: Unpin,
impl UnsafeUnpin for SiteWorkflowswhere
*const LeafNode<Uuid, Arc<GuardianProbe>> is !null: UnsafeUnpin,
PhantomData<(Owned, LeafOrInternal)>: UnsafeUnpin,
PhantomData<Box<(Uuid, Arc<GuardianProbe>)>>: UnsafeUnpin,
*const LeafNode<Uuid, Arc<UpkeepCheck>> is !null: UnsafeUnpin,
PhantomData<Box<(Uuid, Arc<UpkeepCheck>)>>: UnsafeUnpin,
*const LeafNode<Uuid, DigestTarget> is !null: UnsafeUnpin,
PhantomData<Box<(Uuid, DigestTarget)>>: UnsafeUnpin,
*const LeafNode<Uuid, Arc<RepositoryEntry>> is !null: UnsafeUnpin,
PhantomData<Box<(Uuid, Arc<RepositoryEntry>)>>: UnsafeUnpin,
*const LeafNode<Uuid, Arc<PlaybookLearning>> is !null: UnsafeUnpin,
PhantomData<Box<(Uuid, Arc<PlaybookLearning>)>>: UnsafeUnpin,
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ
fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ
Source§fn with_current_context(self) -> WithContext<Self> ⓘ
fn with_current_context(self) -> WithContext<Self> ⓘ
impl<A, B, T> HttpServerConnExec<A, B> for Twhere
B: Body,
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 more