Skip to main content

RuntimePackages

Trait RuntimePackages 

Source
pub trait RuntimePackages:
    Debug
    + Send
    + Sync {
    // Required methods
    fn materialize<'life0, 'life1, 'life2, 'async_trait>(
        &'life0 self,
        attempt: &'life1 RunnerAttempt,
        timings: &'life2 mut PackageTimings,
    ) -> Pin<Box<dyn Future<Output = Result<RunnerVersion, FailureReason>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait,
             'life2: 'async_trait;
    fn release(&self, attempt: AttemptId) -> Result<(), FailureReason>;
    fn prune_obsolete_guarded(
        &self,
        authority: PruneAuthority<'_>,
        attempts: &[RunnerAttempt],
    ) -> Result<(), FailureReason>;
}
Expand description

Package/cache operations used by one attempt.

Required Methods§

Source

fn materialize<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, attempt: &'life1 RunnerAttempt, timings: &'life2 mut PackageTimings, ) -> Pin<Box<dyn Future<Output = Result<RunnerVersion, FailureReason>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Copy the package into attempt’s runtime, adding where the time went to timings.

Source

fn release(&self, attempt: AttemptId) -> Result<(), FailureReason>

Source

fn prune_obsolete_guarded( &self, authority: PruneAuthority<'_>, attempts: &[RunnerAttempt], ) -> Result<(), FailureReason>

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§