1. Registry
  2. Packages
  3. Snowflake Provider
  4. API Docs
  5. ReplicationGroupSecondary
Viewing docs for Snowflake v2.23.0
published on Friday, Nov 6, 2026 by Pulumi
snowflake logo
Viewing docs for Snowflake v2.23.0
published on Friday, Nov 6, 2026 by Pulumi

    Caution: Preview Feature This feature is considered a preview feature in the provider, regardless of the state of the resource in Snowflake. We do not guarantee its stability. It will be reworked and marked as a stable feature in future releases. Breaking changes are expected, even without bumping the major version. To use this feature, add the relevant feature name to previewFeaturesEnabled field in the provider configuration. Please always refer to the Getting Help section in our Github repo to best determine how to get help for your questions.

    Resource used to manage a replication group replica in the target account. For more information, check replication group documentation.

    Example Usage

    Note Instead of using fully_qualified_name, you can reference objects managed outside Terraform by constructing a correct ID, consult identifiers guide.

    import * as pulumi from "@pulumi/pulumi";
    import * as snowflake from "@pulumi/snowflake";
    
    const basic = new snowflake.ReplicationGroupSecondary("basic", {
        name: "replication_group_name",
        primary: "\"<organization_name>\".\"<account_name>\".\"<replication_group_name>\"",
    });
    
    import pulumi
    import pulumi_snowflake as snowflake
    
    basic = snowflake.ReplicationGroupSecondary("basic",
        name="replication_group_name",
        primary="\"<organization_name>\".\"<account_name>\".\"<replication_group_name>\"")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-snowflake/sdk/v2/go/snowflake"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := snowflake.NewReplicationGroupSecondary(ctx, "basic", &snowflake.ReplicationGroupSecondaryArgs{
    			Name:    pulumi.String("replication_group_name"),
    			Primary: pulumi.String("\"<organization_name>\".\"<account_name>\".\"<replication_group_name>\""),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Snowflake = Pulumi.Snowflake;
    
    return await Deployment.RunAsync(() => 
    {
        var basic = new Snowflake.ReplicationGroupSecondary("basic", new()
        {
            Name = "replication_group_name",
            Primary = "\"<organization_name>\".\"<account_name>\".\"<replication_group_name>\"",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.snowflake.ReplicationGroupSecondary;
    import com.pulumi.snowflake.ReplicationGroupSecondaryArgs;
    import java.util.ArrayList;
    import java.util.Arrays;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var basic = new ReplicationGroupSecondary("basic", ReplicationGroupSecondaryArgs.builder()
                .name("replication_group_name")
                .primary("\"<organization_name>\".\"<account_name>\".\"<replication_group_name>\"")
                .build());
    
        }
    }
    
    resources:
      basic:
        type: snowflake:ReplicationGroupSecondary
        properties:
          name: replication_group_name
          primary: '"<organization_name>"."<account_name>"."<replication_group_name>"'
    
    terraform {
      required_providers {
        snowflake = {
          source = "pulumi/snowflake"
        }
      }
    }
    
    resource "snowflake_replication_group_secondary" "basic" {
      lifecycle {
        create_before_destroy = true
      }
      name    = "replication_group_name"
      primary = "\"<organization_name>\".\"<account_name>\".\"<replication_group_name>\""
    }
    

    Note When this replication group becomes primary, Terraform recreates it as a replica of primary. Moving the object to snowflake.ReplicationGroup is a manual state migration. See resource migration.

    Note If a field has a default value, it is shown next to the type in the schema.

    Create ReplicationGroupSecondary Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new ReplicationGroupSecondary(name: string, args?: ReplicationGroupSecondaryArgs, opts?: CustomResourceOptions);
    @overload
    def ReplicationGroupSecondary(resource_name: str,
                                  args: Optional[ReplicationGroupSecondaryArgs] = None,
                                  opts: Optional[ResourceOptions] = None)
    
    @overload
    def ReplicationGroupSecondary(resource_name: str,
                                  opts: Optional[ResourceOptions] = None,
                                  name: Optional[str] = None,
                                  primary: Optional[str] = None)
    func NewReplicationGroupSecondary(ctx *Context, name string, args *ReplicationGroupSecondaryArgs, opts ...ResourceOption) (*ReplicationGroupSecondary, error)
    public ReplicationGroupSecondary(string name, ReplicationGroupSecondaryArgs? args = null, CustomResourceOptions? opts = null)
    public ReplicationGroupSecondary(String name, ReplicationGroupSecondaryArgs args)
    public ReplicationGroupSecondary(String name, ReplicationGroupSecondaryArgs args, CustomResourceOptions options)
    
    type: snowflake:ReplicationGroupSecondary
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    
    resource "snowflake_replication_group_secondary" "name" {
        # resource properties
    }

    Parameters

    name string
    The unique name of the resource.
    args ReplicationGroupSecondaryArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args ReplicationGroupSecondaryArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args ReplicationGroupSecondaryArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args ReplicationGroupSecondaryArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args ReplicationGroupSecondaryArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var replicationGroupSecondaryResource = new Snowflake.ReplicationGroupSecondary("replicationGroupSecondaryResource", new()
    {
        Name = "string",
        Primary = "string",
    });
    
    example, err := snowflake.NewReplicationGroupSecondary(ctx, "replicationGroupSecondaryResource", &snowflake.ReplicationGroupSecondaryArgs{
    	Name:    pulumi.String("string"),
    	Primary: pulumi.String("string"),
    })
    
    resource "snowflake_replication_group_secondary" "replicationGroupSecondaryResource" {
      lifecycle {
        create_before_destroy = true
      }
      name    = "string"
      primary = "string"
    }
    
    var replicationGroupSecondaryResource = new ReplicationGroupSecondary("replicationGroupSecondaryResource", ReplicationGroupSecondaryArgs.builder()
        .name("string")
        .primary("string")
        .build());
    
    replication_group_secondary_resource = snowflake.ReplicationGroupSecondary("replicationGroupSecondaryResource",
        name="string",
        primary="string")
    
    const replicationGroupSecondaryResource = new snowflake.ReplicationGroupSecondary("replicationGroupSecondaryResource", {
        name: "string",
        primary: "string",
    });
    
    type: snowflake:ReplicationGroupSecondary
    properties:
        name: string
        primary: string
    

    ReplicationGroupSecondary Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The ReplicationGroupSecondary resource accepts the following input properties:

    Name string
    Specifies the identifier for the replication group secondary; must be unique for the account. Due to technical limitations (read more here), avoid using the following characters: |, ., ".
    Primary string
    Primary replication group to replicate, as org.account.name. This is the AS REPLICA OF identifier.
    Name string
    Specifies the identifier for the replication group secondary; must be unique for the account. Due to technical limitations (read more here), avoid using the following characters: |, ., ".
    Primary string
    Primary replication group to replicate, as org.account.name. This is the AS REPLICA OF identifier.
    name string
    Specifies the identifier for the replication group secondary; must be unique for the account. Due to technical limitations (read more here), avoid using the following characters: |, ., ".
    primary string
    Primary replication group to replicate, as org.account.name. This is the AS REPLICA OF identifier.
    name String
    Specifies the identifier for the replication group secondary; must be unique for the account. Due to technical limitations (read more here), avoid using the following characters: |, ., ".
    primary String
    Primary replication group to replicate, as org.account.name. This is the AS REPLICA OF identifier.
    name string
    Specifies the identifier for the replication group secondary; must be unique for the account. Due to technical limitations (read more here), avoid using the following characters: |, ., ".
    primary string
    Primary replication group to replicate, as org.account.name. This is the AS REPLICA OF identifier.
    name str
    Specifies the identifier for the replication group secondary; must be unique for the account. Due to technical limitations (read more here), avoid using the following characters: |, ., ".
    primary str
    Primary replication group to replicate, as org.account.name. This is the AS REPLICA OF identifier.
    name String
    Specifies the identifier for the replication group secondary; must be unique for the account. Due to technical limitations (read more here), avoid using the following characters: |, ., ".
    primary String
    Primary replication group to replicate, as org.account.name. This is the AS REPLICA OF identifier.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the ReplicationGroupSecondary resource produces the following output properties:

    FullyQualifiedName string
    Fully qualified name of the resource. For more information, see object name resolution.
    Id string
    The provider-assigned unique ID for this managed resource.
    IsPrimary bool
    Indicates if the replication group is primary. When Terraform detects that the primary status changed outside of Terraform, the resource is recreated.
    ShowOutputs List<ReplicationGroupSecondaryShowOutput>
    Outputs the result of SHOW REPLICATION GROUPS for the given replication group secondary.
    FullyQualifiedName string
    Fully qualified name of the resource. For more information, see object name resolution.
    Id string
    The provider-assigned unique ID for this managed resource.
    IsPrimary bool
    Indicates if the replication group is primary. When Terraform detects that the primary status changed outside of Terraform, the resource is recreated.
    ShowOutputs []ReplicationGroupSecondaryShowOutput
    Outputs the result of SHOW REPLICATION GROUPS for the given replication group secondary.
    fully_qualified_name string
    Fully qualified name of the resource. For more information, see object name resolution.
    id string
    The provider-assigned unique ID for this managed resource.
    is_primary bool
    Indicates if the replication group is primary. When Terraform detects that the primary status changed outside of Terraform, the resource is recreated.
    show_outputs list(object)
    Outputs the result of SHOW REPLICATION GROUPS for the given replication group secondary.
    fullyQualifiedName String
    Fully qualified name of the resource. For more information, see object name resolution.
    id String
    The provider-assigned unique ID for this managed resource.
    isPrimary Boolean
    Indicates if the replication group is primary. When Terraform detects that the primary status changed outside of Terraform, the resource is recreated.
    showOutputs List<ReplicationGroupSecondaryShowOutput>
    Outputs the result of SHOW REPLICATION GROUPS for the given replication group secondary.
    fullyQualifiedName string
    Fully qualified name of the resource. For more information, see object name resolution.
    id string
    The provider-assigned unique ID for this managed resource.
    isPrimary boolean
    Indicates if the replication group is primary. When Terraform detects that the primary status changed outside of Terraform, the resource is recreated.
    showOutputs ReplicationGroupSecondaryShowOutput[]
    Outputs the result of SHOW REPLICATION GROUPS for the given replication group secondary.
    fully_qualified_name str
    Fully qualified name of the resource. For more information, see object name resolution.
    id str
    The provider-assigned unique ID for this managed resource.
    is_primary bool
    Indicates if the replication group is primary. When Terraform detects that the primary status changed outside of Terraform, the resource is recreated.
    show_outputs Sequence[ReplicationGroupSecondaryShowOutput]
    Outputs the result of SHOW REPLICATION GROUPS for the given replication group secondary.
    fullyQualifiedName String
    Fully qualified name of the resource. For more information, see object name resolution.
    id String
    The provider-assigned unique ID for this managed resource.
    isPrimary Boolean
    Indicates if the replication group is primary. When Terraform detects that the primary status changed outside of Terraform, the resource is recreated.
    showOutputs List<Property Map>
    Outputs the result of SHOW REPLICATION GROUPS for the given replication group secondary.

    Look up Existing ReplicationGroupSecondary Resource

    Get an existing ReplicationGroupSecondary resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: ReplicationGroupSecondaryState, opts?: CustomResourceOptions): ReplicationGroupSecondary
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            fully_qualified_name: Optional[str] = None,
            is_primary: Optional[bool] = None,
            name: Optional[str] = None,
            primary: Optional[str] = None,
            show_outputs: Optional[Sequence[ReplicationGroupSecondaryShowOutputArgs]] = None) -> ReplicationGroupSecondary
    func GetReplicationGroupSecondary(ctx *Context, name string, id IDInput, state *ReplicationGroupSecondaryState, opts ...ResourceOption) (*ReplicationGroupSecondary, error)
    public static ReplicationGroupSecondary Get(string name, Input<string> id, ReplicationGroupSecondaryState? state, CustomResourceOptions? opts = null)
    public static ReplicationGroupSecondary get(String name, Output<String> id, ReplicationGroupSecondaryState state, CustomResourceOptions options)
    resources:  _:    type: snowflake:ReplicationGroupSecondary    get:      id: ${id}
    import {
      to = snowflake_replication_group_secondary.example
      id = "${id}"
    }
    
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    FullyQualifiedName string
    Fully qualified name of the resource. For more information, see object name resolution.
    IsPrimary bool
    Indicates if the replication group is primary. When Terraform detects that the primary status changed outside of Terraform, the resource is recreated.
    Name string
    Specifies the identifier for the replication group secondary; must be unique for the account. Due to technical limitations (read more here), avoid using the following characters: |, ., ".
    Primary string
    Primary replication group to replicate, as org.account.name. This is the AS REPLICA OF identifier.
    ShowOutputs List<ReplicationGroupSecondaryShowOutput>
    Outputs the result of SHOW REPLICATION GROUPS for the given replication group secondary.
    FullyQualifiedName string
    Fully qualified name of the resource. For more information, see object name resolution.
    IsPrimary bool
    Indicates if the replication group is primary. When Terraform detects that the primary status changed outside of Terraform, the resource is recreated.
    Name string
    Specifies the identifier for the replication group secondary; must be unique for the account. Due to technical limitations (read more here), avoid using the following characters: |, ., ".
    Primary string
    Primary replication group to replicate, as org.account.name. This is the AS REPLICA OF identifier.
    ShowOutputs []ReplicationGroupSecondaryShowOutputArgs
    Outputs the result of SHOW REPLICATION GROUPS for the given replication group secondary.
    fully_qualified_name string
    Fully qualified name of the resource. For more information, see object name resolution.
    is_primary bool
    Indicates if the replication group is primary. When Terraform detects that the primary status changed outside of Terraform, the resource is recreated.
    name string
    Specifies the identifier for the replication group secondary; must be unique for the account. Due to technical limitations (read more here), avoid using the following characters: |, ., ".
    primary string
    Primary replication group to replicate, as org.account.name. This is the AS REPLICA OF identifier.
    show_outputs list(object)
    Outputs the result of SHOW REPLICATION GROUPS for the given replication group secondary.
    fullyQualifiedName String
    Fully qualified name of the resource. For more information, see object name resolution.
    isPrimary Boolean
    Indicates if the replication group is primary. When Terraform detects that the primary status changed outside of Terraform, the resource is recreated.
    name String
    Specifies the identifier for the replication group secondary; must be unique for the account. Due to technical limitations (read more here), avoid using the following characters: |, ., ".
    primary String
    Primary replication group to replicate, as org.account.name. This is the AS REPLICA OF identifier.
    showOutputs List<ReplicationGroupSecondaryShowOutput>
    Outputs the result of SHOW REPLICATION GROUPS for the given replication group secondary.
    fullyQualifiedName string
    Fully qualified name of the resource. For more information, see object name resolution.
    isPrimary boolean
    Indicates if the replication group is primary. When Terraform detects that the primary status changed outside of Terraform, the resource is recreated.
    name string
    Specifies the identifier for the replication group secondary; must be unique for the account. Due to technical limitations (read more here), avoid using the following characters: |, ., ".
    primary string
    Primary replication group to replicate, as org.account.name. This is the AS REPLICA OF identifier.
    showOutputs ReplicationGroupSecondaryShowOutput[]
    Outputs the result of SHOW REPLICATION GROUPS for the given replication group secondary.
    fully_qualified_name str
    Fully qualified name of the resource. For more information, see object name resolution.
    is_primary bool
    Indicates if the replication group is primary. When Terraform detects that the primary status changed outside of Terraform, the resource is recreated.
    name str
    Specifies the identifier for the replication group secondary; must be unique for the account. Due to technical limitations (read more here), avoid using the following characters: |, ., ".
    primary str
    Primary replication group to replicate, as org.account.name. This is the AS REPLICA OF identifier.
    show_outputs Sequence[ReplicationGroupSecondaryShowOutputArgs]
    Outputs the result of SHOW REPLICATION GROUPS for the given replication group secondary.
    fullyQualifiedName String
    Fully qualified name of the resource. For more information, see object name resolution.
    isPrimary Boolean
    Indicates if the replication group is primary. When Terraform detects that the primary status changed outside of Terraform, the resource is recreated.
    name String
    Specifies the identifier for the replication group secondary; must be unique for the account. Due to technical limitations (read more here), avoid using the following characters: |, ., ".
    primary String
    Primary replication group to replicate, as org.account.name. This is the AS REPLICA OF identifier.
    showOutputs List<Property Map>
    Outputs the result of SHOW REPLICATION GROUPS for the given replication group secondary.

    Supporting Types

    ReplicationGroupSecondaryShowOutput, ReplicationGroupSecondaryShowOutputArgs

    Import

    $ pulumi import snowflake:index/replicationGroupSecondary:ReplicationGroupSecondary example '"<replication_group_name>"'
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    Snowflake pulumi/pulumi-snowflake
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the snowflake Terraform Provider.
    snowflake logo
    Viewing docs for Snowflake v2.23.0
    published on Friday, Nov 6, 2026 by Pulumi

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial