azure-native.sql.ReplicationLink
Explore with Pulumi AI
A replication link. Azure REST API version: 2023-05-01-preview.
Other available API versions: 2023-08-01-preview.
Example Usage
Updates Replication Link
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var replicationLink = new AzureNative.Sql.ReplicationLink("replicationLink", new()
{
DatabaseName = "gamma-db",
LinkId = "00000000-1111-2222-3333-666666666666",
LinkType = AzureNative.Sql.ReplicationLinkType.STANDBY,
ResourceGroupName = "Default",
ServerName = "sourcesvr",
});
});
package main
import (
sql "github.com/pulumi/pulumi-azure-native-sdk/sql/v2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := sql.NewReplicationLink(ctx, "replicationLink", &sql.ReplicationLinkArgs{
DatabaseName: pulumi.String("gamma-db"),
LinkId: pulumi.String("00000000-1111-2222-3333-666666666666"),
LinkType: pulumi.String(sql.ReplicationLinkTypeSTANDBY),
ResourceGroupName: pulumi.String("Default"),
ServerName: pulumi.String("sourcesvr"),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.sql.ReplicationLink;
import com.pulumi.azurenative.sql.ReplicationLinkArgs;
import java.util.List;
import java.util.ArrayList;
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 replicationLink = new ReplicationLink("replicationLink", ReplicationLinkArgs.builder()
.databaseName("gamma-db")
.linkId("00000000-1111-2222-3333-666666666666")
.linkType("STANDBY")
.resourceGroupName("Default")
.serverName("sourcesvr")
.build());
}
}
import pulumi
import pulumi_azure_native as azure_native
replication_link = azure_native.sql.ReplicationLink("replicationLink",
database_name="gamma-db",
link_id="00000000-1111-2222-3333-666666666666",
link_type=azure_native.sql.ReplicationLinkType.STANDBY,
resource_group_name="Default",
server_name="sourcesvr")
import * as pulumi from "@pulumi/pulumi";
import * as azure_native from "@pulumi/azure-native";
const replicationLink = new azure_native.sql.ReplicationLink("replicationLink", {
databaseName: "gamma-db",
linkId: "00000000-1111-2222-3333-666666666666",
linkType: azure_native.sql.ReplicationLinkType.STANDBY,
resourceGroupName: "Default",
serverName: "sourcesvr",
});
resources:
replicationLink:
type: azure-native:sql:ReplicationLink
properties:
databaseName: gamma-db
linkId: 00000000-1111-2222-3333-666666666666
linkType: STANDBY
resourceGroupName: Default
serverName: sourcesvr
Create ReplicationLink Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new ReplicationLink(name: string, args: ReplicationLinkArgs, opts?: CustomResourceOptions);
@overload
def ReplicationLink(resource_name: str,
args: ReplicationLinkArgs,
opts: Optional[ResourceOptions] = None)
@overload
def ReplicationLink(resource_name: str,
opts: Optional[ResourceOptions] = None,
database_name: Optional[str] = None,
resource_group_name: Optional[str] = None,
server_name: Optional[str] = None,
link_id: Optional[str] = None,
link_type: Optional[Union[str, ReplicationLinkType]] = None)
func NewReplicationLink(ctx *Context, name string, args ReplicationLinkArgs, opts ...ResourceOption) (*ReplicationLink, error)
public ReplicationLink(string name, ReplicationLinkArgs args, CustomResourceOptions? opts = null)
public ReplicationLink(String name, ReplicationLinkArgs args)
public ReplicationLink(String name, ReplicationLinkArgs args, CustomResourceOptions options)
type: azure-native:sql:ReplicationLink
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args ReplicationLinkArgs
- 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 ReplicationLinkArgs
- 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 ReplicationLinkArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ReplicationLinkArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ReplicationLinkArgs
- 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 replicationLinkResource = new AzureNative.Sql.ReplicationLink("replicationLinkResource", new()
{
DatabaseName = "string",
ResourceGroupName = "string",
ServerName = "string",
LinkId = "string",
LinkType = "string",
});
example, err := sql.NewReplicationLink(ctx, "replicationLinkResource", &sql.ReplicationLinkArgs{
DatabaseName: pulumi.String("string"),
ResourceGroupName: pulumi.String("string"),
ServerName: pulumi.String("string"),
LinkId: pulumi.String("string"),
LinkType: pulumi.String("string"),
})
var replicationLinkResource = new ReplicationLink("replicationLinkResource", ReplicationLinkArgs.builder()
.databaseName("string")
.resourceGroupName("string")
.serverName("string")
.linkId("string")
.linkType("string")
.build());
replication_link_resource = azure_native.sql.ReplicationLink("replicationLinkResource",
database_name="string",
resource_group_name="string",
server_name="string",
link_id="string",
link_type="string")
const replicationLinkResource = new azure_native.sql.ReplicationLink("replicationLinkResource", {
databaseName: "string",
resourceGroupName: "string",
serverName: "string",
linkId: "string",
linkType: "string",
});
type: azure-native:sql:ReplicationLink
properties:
databaseName: string
linkId: string
linkType: string
resourceGroupName: string
serverName: string
ReplicationLink Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
The ReplicationLink resource accepts the following input properties:
- Database
Name string - The name of the database.
- Resource
Group stringName - The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
- Server
Name string - The name of the server.
- Link
Id string - Link
Type string | Pulumi.Azure Native. Sql. Replication Link Type - Link type (GEO, NAMED, STANDBY). Update operation does not support NAMED.
- Database
Name string - The name of the database.
- Resource
Group stringName - The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
- Server
Name string - The name of the server.
- Link
Id string - Link
Type string | ReplicationLink Type - Link type (GEO, NAMED, STANDBY). Update operation does not support NAMED.
- database
Name String - The name of the database.
- resource
Group StringName - The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
- server
Name String - The name of the server.
- link
Id String - link
Type String | ReplicationLink Type - Link type (GEO, NAMED, STANDBY). Update operation does not support NAMED.
- database
Name string - The name of the database.
- resource
Group stringName - The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
- server
Name string - The name of the server.
- link
Id string - link
Type string | ReplicationLink Type - Link type (GEO, NAMED, STANDBY). Update operation does not support NAMED.
- database_
name str - The name of the database.
- resource_
group_ strname - The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
- server_
name str - The name of the server.
- link_
id str - link_
type str | ReplicationLink Type - Link type (GEO, NAMED, STANDBY). Update operation does not support NAMED.
- database
Name String - The name of the database.
- resource
Group StringName - The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
- server
Name String - The name of the server.
- link
Id String - link
Type String | "GEO" | "NAMED" | "STANDBY" - Link type (GEO, NAMED, STANDBY). Update operation does not support NAMED.
Outputs
All input properties are implicitly available as output properties. Additionally, the ReplicationLink resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Is
Termination boolAllowed - Whether the user is currently allowed to terminate the link.
- Name string
- Resource name.
- Partner
Database string - Resource partner database.
- Partner
Database stringId - Resource partner database Id.
- Partner
Location string - Resource partner location.
- Partner
Role string - Partner replication role.
- Partner
Server string - Resource partner server.
- Percent
Complete int - Seeding completion percentage for the link.
- Replication
Mode string - Replication mode.
- Replication
State string - Replication state (PENDING, SEEDING, CATCHUP, SUSPENDED).
- Role string
- Local replication role.
- Start
Time string - Time at which the link was created.
- Type string
- Resource type.
- Id string
- The provider-assigned unique ID for this managed resource.
- Is
Termination boolAllowed - Whether the user is currently allowed to terminate the link.
- Name string
- Resource name.
- Partner
Database string - Resource partner database.
- Partner
Database stringId - Resource partner database Id.
- Partner
Location string - Resource partner location.
- Partner
Role string - Partner replication role.
- Partner
Server string - Resource partner server.
- Percent
Complete int - Seeding completion percentage for the link.
- Replication
Mode string - Replication mode.
- Replication
State string - Replication state (PENDING, SEEDING, CATCHUP, SUSPENDED).
- Role string
- Local replication role.
- Start
Time string - Time at which the link was created.
- Type string
- Resource type.
- id String
- The provider-assigned unique ID for this managed resource.
- is
Termination BooleanAllowed - Whether the user is currently allowed to terminate the link.
- name String
- Resource name.
- partner
Database String - Resource partner database.
- partner
Database StringId - Resource partner database Id.
- partner
Location String - Resource partner location.
- partner
Role String - Partner replication role.
- partner
Server String - Resource partner server.
- percent
Complete Integer - Seeding completion percentage for the link.
- replication
Mode String - Replication mode.
- replication
State String - Replication state (PENDING, SEEDING, CATCHUP, SUSPENDED).
- role String
- Local replication role.
- start
Time String - Time at which the link was created.
- type String
- Resource type.
- id string
- The provider-assigned unique ID for this managed resource.
- is
Termination booleanAllowed - Whether the user is currently allowed to terminate the link.
- name string
- Resource name.
- partner
Database string - Resource partner database.
- partner
Database stringId - Resource partner database Id.
- partner
Location string - Resource partner location.
- partner
Role string - Partner replication role.
- partner
Server string - Resource partner server.
- percent
Complete number - Seeding completion percentage for the link.
- replication
Mode string - Replication mode.
- replication
State string - Replication state (PENDING, SEEDING, CATCHUP, SUSPENDED).
- role string
- Local replication role.
- start
Time string - Time at which the link was created.
- type string
- Resource type.
- id str
- The provider-assigned unique ID for this managed resource.
- is_
termination_ boolallowed - Whether the user is currently allowed to terminate the link.
- name str
- Resource name.
- partner_
database str - Resource partner database.
- partner_
database_ strid - Resource partner database Id.
- partner_
location str - Resource partner location.
- partner_
role str - Partner replication role.
- partner_
server str - Resource partner server.
- percent_
complete int - Seeding completion percentage for the link.
- replication_
mode str - Replication mode.
- replication_
state str - Replication state (PENDING, SEEDING, CATCHUP, SUSPENDED).
- role str
- Local replication role.
- start_
time str - Time at which the link was created.
- type str
- Resource type.
- id String
- The provider-assigned unique ID for this managed resource.
- is
Termination BooleanAllowed - Whether the user is currently allowed to terminate the link.
- name String
- Resource name.
- partner
Database String - Resource partner database.
- partner
Database StringId - Resource partner database Id.
- partner
Location String - Resource partner location.
- partner
Role String - Partner replication role.
- partner
Server String - Resource partner server.
- percent
Complete Number - Seeding completion percentage for the link.
- replication
Mode String - Replication mode.
- replication
State String - Replication state (PENDING, SEEDING, CATCHUP, SUSPENDED).
- role String
- Local replication role.
- start
Time String - Time at which the link was created.
- type String
- Resource type.
Supporting Types
ReplicationLinkType, ReplicationLinkTypeArgs
- GEO
- GEO
- NAMED
- NAMED
- STANDBY
- STANDBY
- Replication
Link Type GEO - GEO
- Replication
Link Type NAMED - NAMED
- Replication
Link Type STANDBY - STANDBY
- GEO
- GEO
- NAMED
- NAMED
- STANDBY
- STANDBY
- GEO
- GEO
- NAMED
- NAMED
- STANDBY
- STANDBY
- GEO
- GEO
- NAMED
- NAMED
- STANDBY
- STANDBY
- "GEO"
- GEO
- "NAMED"
- NAMED
- "STANDBY"
- STANDBY
Import
An existing resource can be imported using its type token, name, and identifier, e.g.
$ pulumi import azure-native:sql:ReplicationLink 00000000-1111-2222-3333-666666666666 /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/replicationLinks/{linkId}
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Azure Native pulumi/pulumi-azure-native
- License
- Apache-2.0