Skip to main content

get_apply_state

Function get_apply_state 

Source
pub(super) async fn get_apply_state(
    client: &Client,
    deploy_id: &str,
) -> Result<ApplyState, ConnectionError>
Expand description

Get the current apply state for a deployment.

Checks for the existence of _mz_deploy.apply_<deploy_id>_pre schema and its comment to determine the state:

  • Schema doesn’t exist → NotStarted
  • Schema exists with comment ‘swapped=false’ → PreSwap
  • Schema exists with comment ‘swapped=true’ → PostSwap