Skip to main content

PromotionService

Trait PromotionService 

Source
pub trait PromotionService: Send + Sync {
    // Required method
    fn promote_entity<'life0, 'async_trait>(
        &'life0 self,
        workspace_id: Uuid,
        entity_type: PromotionEntityType,
        entity_id: String,
        entity_version: Option<String>,
        from_environment: MockEnvironmentName,
        to_environment: MockEnvironmentName,
        promoted_by: Uuid,
        comments: Option<String>,
    ) -> Pin<Box<dyn Future<Output = Result<Uuid, Error>> + Send + 'async_trait>>
       where 'life0: 'async_trait,
             Self: 'async_trait;
}
Expand description

Trait for services that can perform promotions.

Allows pipeline steps and other consumers to trigger promotions without creating circular dependencies between crates.

Required Methods§

Source

fn promote_entity<'life0, 'async_trait>( &'life0 self, workspace_id: Uuid, entity_type: PromotionEntityType, entity_id: String, entity_version: Option<String>, from_environment: MockEnvironmentName, to_environment: MockEnvironmentName, promoted_by: Uuid, comments: Option<String>, ) -> Pin<Box<dyn Future<Output = Result<Uuid, Error>> + Send + 'async_trait>>
where 'life0: 'async_trait, Self: 'async_trait,

Promote an entity from one environment to another.

Implementors§