ObjectReplicationPoliciesOperations Class
Warning
DO NOT instantiate this class directly.
Instead, you should access the following operations through
<xref:object_replication_policies> attribute.
- Inheritance
-
builtins.objectObjectReplicationPoliciesOperations
Constructor
ObjectReplicationPoliciesOperations(*args, **kwargs)
Methods
create_or_update |
Create or update the object replication policy of the storage account. |
delete |
Deletes the object replication policy associated with the specified storage account. |
get |
Get the object replication policy of the storage account by policy ID. |
list |
List the object replication policies associated with the storage account. |
create_or_update
Create or update the object replication policy of the storage account.
create_or_update(resource_group_name: str, account_name: str, object_replication_policy_id: str, properties: _models.ObjectReplicationPolicy, *, content_type: str = 'application/json', **kwargs: Any) -> _models.ObjectReplicationPolicy
Parameters
Name | Description |
---|---|
resource_group_name
Required
|
The name of the resource group within the user's subscription. The name is case insensitive. Required. |
account_name
Required
|
The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. Required. |
object_replication_policy_id
Required
|
For the destination account, provide the value 'default'. Configure the policy on the destination account first. For the source account, provide the value of the policy ID that is returned when you download the policy that was defined on the destination account. The policy is downloaded as a JSON file. Required. |
properties
Required
|
The object replication policy set to a storage account. A unique policy ID will be created if absent. Is either a ObjectReplicationPolicy type or a IO[bytes] type. Required. |
Returns
Type | Description |
---|---|
ObjectReplicationPolicy or the result of cls(response) |
Exceptions
Type | Description |
---|---|
delete
Deletes the object replication policy associated with the specified storage account.
delete(resource_group_name: str, account_name: str, object_replication_policy_id: str, **kwargs: Any) -> None
Parameters
Name | Description |
---|---|
resource_group_name
Required
|
The name of the resource group within the user's subscription. The name is case insensitive. Required. |
account_name
Required
|
The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. Required. |
object_replication_policy_id
Required
|
For the destination account, provide the value 'default'. Configure the policy on the destination account first. For the source account, provide the value of the policy ID that is returned when you download the policy that was defined on the destination account. The policy is downloaded as a JSON file. Required. |
Returns
Type | Description |
---|---|
None or the result of cls(response) |
Exceptions
Type | Description |
---|---|
get
Get the object replication policy of the storage account by policy ID.
get(resource_group_name: str, account_name: str, object_replication_policy_id: str, **kwargs: Any) -> ObjectReplicationPolicy
Parameters
Name | Description |
---|---|
resource_group_name
Required
|
The name of the resource group within the user's subscription. The name is case insensitive. Required. |
account_name
Required
|
The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. Required. |
object_replication_policy_id
Required
|
For the destination account, provide the value 'default'. Configure the policy on the destination account first. For the source account, provide the value of the policy ID that is returned when you download the policy that was defined on the destination account. The policy is downloaded as a JSON file. Required. |
Returns
Type | Description |
---|---|
ObjectReplicationPolicy or the result of cls(response) |
Exceptions
Type | Description |
---|---|
list
List the object replication policies associated with the storage account.
list(resource_group_name: str, account_name: str, **kwargs: Any) -> Iterable[ObjectReplicationPolicy]
Parameters
Name | Description |
---|---|
resource_group_name
Required
|
The name of the resource group within the user's subscription. The name is case insensitive. Required. |
account_name
Required
|
The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. Required. |
Returns
Type | Description |
---|---|
An iterator like instance of either ObjectReplicationPolicy or the result of cls(response) |
Exceptions
Type | Description |
---|---|
Attributes
models
models = <module 'azure.mgmt.storage.v2021_06_01.models' from 'C:\\hostedtoolcache\\windows\\Python\\3.11.9\\x64\\Lib\\site-packages\\azure\\mgmt\\storage\\v2021_06_01\\models\\__init__.py'>
Azure SDK for Python