Skip to main content

unplan_create_cluster

Function unplan_create_cluster 

Source
pub fn unplan_create_cluster(
    scx: &StatementContext<'_>,
    _: CreateClusterPlan,
) -> Result<CreateClusterStatement<Aug>, PlanError>
Expand description

Convert a CreateClusterPlan into a CreateClusterStatement.

The reverse of plan_create_cluster, so this renders IF NOT EXISTS when the plan carries it. A caller that wants the cluster’s canonical definition rather than a faithful reverse must pass if_not_exists: false, which is what Cluster::try_to_plan produces for SHOW CREATE CLUSTER.