pub struct DeploymentPlan {
pub created_at: DateTime<Utc>,
pub config_hash: String,
pub actions: Vec<PlannedAction>,
pub estimated_cost_delta: Option<f64>,
pub passes_guardrails: bool,
pub guardrail_violations: Vec<String>,
}Expand description
A complete deployment plan.
Fields§
§created_at: DateTime<Utc>When the plan was created.
config_hash: StringConfiguration hash this plan is based on.
actions: Vec<PlannedAction>Planned actions in execution order.
estimated_cost_delta: Option<f64>Estimated hourly cost delta (positive = increase).
passes_guardrails: boolWhether the plan passes guardrails.
guardrail_violations: Vec<String>Guardrail violations (if any).
Implementations§
Source§impl DeploymentPlan
impl DeploymentPlan
Sourcepub fn from_diff(
diff: &DiffResult,
config: &DeployConfig,
config_hash: &str,
) -> Self
pub fn from_diff( diff: &DiffResult, config: &DeployConfig, config_hash: &str, ) -> Self
Creates a new plan from a diff result.
Sourcepub const fn action_count(&self) -> usize
pub const fn action_count(&self) -> usize
Returns the number of actions.
Sourcepub fn create_count(&self) -> usize
pub fn create_count(&self) -> usize
Returns the number of create actions.
Sourcepub fn delete_count(&self) -> usize
pub fn delete_count(&self) -> usize
Returns the number of delete actions.
Sourcepub fn ready_actions(&self) -> Vec<&PlannedAction>
pub fn ready_actions(&self) -> Vec<&PlannedAction>
Returns actions that can be executed immediately (no dependencies).
Sourcepub fn dependent_actions(
&self,
action_idx: usize,
) -> Vec<(usize, &PlannedAction)>
pub fn dependent_actions( &self, action_idx: usize, ) -> Vec<(usize, &PlannedAction)>
Gets actions that depend on a specific action index.
Trait Implementations§
Source§impl Debug for DeploymentPlan
impl Debug for DeploymentPlan
Auto Trait Implementations§
impl Freeze for DeploymentPlan
impl RefUnwindSafe for DeploymentPlan
impl Send for DeploymentPlan
impl Sync for DeploymentPlan
impl Unpin for DeploymentPlan
impl UnwindSafe for DeploymentPlan
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> 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 moreCreates a shared type from an unshared type.
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
Source§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.
Source§impl<T> ValidateIp for Twhere
T: ToString,
impl<T> ValidateIp for Twhere
T: ToString,
Source§fn validate_ipv4(&self) -> bool
fn validate_ipv4(&self) -> bool
Validates whether the given string is an IP V4
Source§fn validate_ipv6(&self) -> bool
fn validate_ipv6(&self) -> bool
Validates whether the given string is an IP V6
Source§fn validate_ip(&self) -> bool
fn validate_ip(&self) -> bool
Validates whether the given string is an IP