Skip to main content

replication_protection_container_mappings

Creates, updates, deletes, gets or lists a replication_protection_container_mappings resource.

Overview

Namereplication_protection_container_mappings
TypeResource
Idazure.recovery_services_site_recovery.replication_protection_container_mappings

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
idstringFully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}.
namestringThe name of the resource.
healthstringHealth of pairing.
healthErrorDetailsarrayHealth error.
locationstringResource Location.
policyFriendlyNamestringFriendly name of replication policy.
policyIdstringPolicy ARM Id.
providerSpecificDetailsobjectProvider specific provider details.
sourceFabricFriendlyNamestringFriendly name of source fabric.
sourceProtectionContainerFriendlyNamestringFriendly name of source protection container.
statestringAssociation Status.
systemDataobjectAzure Resource Manager metadata containing createdBy and modifiedBy information.
targetFabricFriendlyNamestringFriendly name of target fabric.
targetProtectionContainerFriendlyNamestringFriendly name of paired container.
targetProtectionContainerIdstringPaired protection container ARM ID.
typestringThe type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts".

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectresource_group_name, resource_name, fabric_name, protection_container_name, mapping_name, subscription_idGets a protection container mapping. Gets the details of a protection container mapping.
list_by_replication_protection_containersselectresource_group_name, resource_name, fabric_name, protection_container_name, subscription_idGets the list of protection container mappings for a protection container. Lists the protection container mappings for a protection container.
listselectresource_group_name, resource_name, subscription_idGets the list of all protection container mappings in a vault. Lists the protection container mappings in the vault.
createinsertresource_group_name, resource_name, fabric_name, protection_container_name, mapping_name, subscription_idCreate protection container mapping. The operation to create a protection container mapping.
updateupdateresource_group_name, resource_name, fabric_name, protection_container_name, mapping_name, subscription_idUpdate protection container mapping. The operation to update protection container mapping.
deletedeleteresource_group_name, resource_name, fabric_name, protection_container_name, mapping_name, subscription_idRemove protection container mapping. The operation to delete or remove a protection container mapping.
purgeexecresource_group_name, resource_name, fabric_name, protection_container_name, mapping_name, subscription_idPurge protection container mapping. The operation to purge(force delete) a protection container mapping.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
fabric_namestringFabric name. Required.
mapping_namestringProtection Container mapping name. Required.
protection_container_namestringProtection container name. Required.
resource_group_namestringThe name of the resource group. The name is case insensitive. Required.
resource_namestringThe name of the Vault. Required.
subscription_idstring

SELECT examples

Gets a protection container mapping. Gets the details of a protection container mapping.

SELECT
id,
name,
health,
healthErrorDetails,
location,
policyFriendlyName,
policyId,
providerSpecificDetails,
sourceFabricFriendlyName,
sourceProtectionContainerFriendlyName,
state,
systemData,
targetFabricFriendlyName,
targetProtectionContainerFriendlyName,
targetProtectionContainerId,
type
FROM azure.recovery_services_site_recovery.replication_protection_container_mappings
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND resource_name = '{{ resource_name }}' -- required
AND fabric_name = '{{ fabric_name }}' -- required
AND protection_container_name = '{{ protection_container_name }}' -- required
AND mapping_name = '{{ mapping_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;

INSERT examples

Create protection container mapping. The operation to create a protection container mapping.

INSERT INTO azure.recovery_services_site_recovery.replication_protection_container_mappings (
properties,
resource_group_name,
resource_name,
fabric_name,
protection_container_name,
mapping_name,
subscription_id
)
SELECT
'{{ properties }}',
'{{ resource_group_name }}',
'{{ resource_name }}',
'{{ fabric_name }}',
'{{ protection_container_name }}',
'{{ mapping_name }}',
'{{ subscription_id }}'
RETURNING
id,
name,
location,
properties,
systemData,
type
;

UPDATE examples

Update protection container mapping. The operation to update protection container mapping.

UPDATE azure.recovery_services_site_recovery.replication_protection_container_mappings
SET
properties = '{{ properties }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND resource_name = '{{ resource_name }}' --required
AND fabric_name = '{{ fabric_name }}' --required
AND protection_container_name = '{{ protection_container_name }}' --required
AND mapping_name = '{{ mapping_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
RETURNING
id,
name,
location,
properties,
systemData,
type;

DELETE examples

Remove protection container mapping. The operation to delete or remove a protection container mapping.

DELETE FROM azure.recovery_services_site_recovery.replication_protection_container_mappings
WHERE resource_group_name = '{{ resource_group_name }}' --required
AND resource_name = '{{ resource_name }}' --required
AND fabric_name = '{{ fabric_name }}' --required
AND protection_container_name = '{{ protection_container_name }}' --required
AND mapping_name = '{{ mapping_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
;

Lifecycle Methods

Purge protection container mapping. The operation to purge(force delete) a protection container mapping.

EXEC azure.recovery_services_site_recovery.replication_protection_container_mappings.purge 
@resource_group_name='{{ resource_group_name }}' --required,
@resource_name='{{ resource_name }}' --required,
@fabric_name='{{ fabric_name }}' --required,
@protection_container_name='{{ protection_container_name }}' --required,
@mapping_name='{{ mapping_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
;