Skip to main content

load_from_database

Function load_from_database 

Source
pub(crate) async fn load_from_database(
    client: &Client,
    environment: Option<&str>,
) -> Result<DeploymentSnapshot, DeploymentSnapshotError>
Expand description

Load the current deployment state snapshot from the database for a specific environment.

§Arguments

  • client - Database client connection
  • environment - None for production, Some(“staging”) for staging environments

§Returns

DeploymentSnapshot with current deployment state, or empty snapshot if no deployments exist