Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add LCM Snapshot and Version Actions to June19 and Aug20-preview. Add LAT support to June19 #12684

Merged
merged 3 commits into from
Jan 29, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,100 @@
{
"parameters": {
"subscriptionId": "{subscription-id}",
"resourceGroupName": "res7687",
"accountName": "sto9699",
"managementPolicyName": "default",
"api-version": "2020-08-01-preview",
"monitor": "true",
"properties": {
"properties": {
"policy": {
"rules": [
{
"enabled": true,
"name": "olcmtest1",
"type": "Lifecycle",
"definition": {
"filters": {
"blobTypes": [
"blockBlob",
"appendBlob"
],
"prefixMatch": [
"olcmtestcontainer1"
]
},
"actions": {
"baseBlob": {
"delete": {
"daysAfterModificationGreaterThan": 90
}
},
"snapshot": {
"delete": {
"daysAfterCreationGreaterThan": 90
}
},
"version": {
"delete": {
"daysAfterCreationGreaterThan": 90
}
}
}
}
}
]
}
}
}
},
"responses": {
"200": {
"body": {
"id": "/subscriptions/{subscription-id}/resourceGroups/res7231/providers/Microsoft.Storage/storageAccounts/sto288/managementPolicies/default",
"name": "DefaultManagementPolicy",
"type": "Microsoft.Storage/storageAccounts/managementPolicies",
"properties": {
"policy": {
"rules": [
{
"enabled": true,
"name": "olcmtest1",
"type": "Lifecycle",
"definition": {
"filters": {
"blobTypes": [
"blockBlob",
"appendBlob"
],
"prefixMatch": [
"olcmtestcontainer1"
]
},
"actions": {
"baseBlob": {
"delete": {
"daysAfterModificationGreaterThan": 90
}
},
"snapshot": {
"delete": {
"daysAfterCreationGreaterThan": 90
}
},
"version": {
"delete": {
"daysAfterCreationGreaterThan": 90
}
}
}
}
}
]
},
"lastModifiedTime": "2018-06-08T02:53:39.0932539Z"
}
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,134 @@
{
"parameters": {
"subscriptionId": "{subscription-id}",
"resourceGroupName": "res7687",
"accountName": "sto9699",
"managementPolicyName": "default",
"api-version": "2020-08-01-preview",
"monitor": "true",
"properties": {
"properties": {
"policy": {
"rules": [
{
"enabled": true,
"name": "olcmtest1",
"type": "Lifecycle",
"definition": {
"filters": {
"blobTypes": [
"blockBlob"
],
"prefixMatch": [
"olcmtestcontainer1"
]
},
"actions": {
"baseBlob": {
"tierToCool": {
"daysAfterModificationGreaterThan": 30
},
"tierToArchive": {
"daysAfterModificationGreaterThan": 90
},
"delete": {
"daysAfterModificationGreaterThan": 1000
}
},
"snapshot": {
"tierToCool": {
"daysAfterCreationGreaterThan": 30
},
"tierToArchive": {
"daysAfterCreationGreaterThan": 90
},
"delete": {
"daysAfterCreationGreaterThan": 1000
}
},
"version": {
"tierToCool": {
"daysAfterCreationGreaterThan": 30
},
"tierToArchive": {
"daysAfterCreationGreaterThan": 90
},
"delete": {
"daysAfterCreationGreaterThan": 1000
}
}
}
}
}
]
}
}
}
},
"responses": {
"200": {
"body": {
"id": "/subscriptions/{subscription-id}/resourceGroups/res7231/providers/Microsoft.Storage/storageAccounts/sto288/managementPolicies/default",
"name": "DefaultManagementPolicy",
"type": "Microsoft.Storage/storageAccounts/managementPolicies",
"properties": {
"policy": {
"rules": [
{
"enabled": true,
"name": "olcmtest1",
"type": "Lifecycle",
"definition": {
"filters": {
"blobTypes": [
"blockBlob"
],
"prefixMatch": [
"olcmtestcontainer1"
]
},
"actions": {
"baseBlob": {
"tierToCool": {
"daysAfterModificationGreaterThan": 30
},
"tierToArchive": {
"daysAfterModificationGreaterThan": 90
},
"delete": {
"daysAfterModificationGreaterThan": 1000
}
},
"snapshot": {
"tierToCool": {
"daysAfterCreationGreaterThan": 30
},
"tierToArchive": {
"daysAfterCreationGreaterThan": 90
},
"delete": {
"daysAfterCreationGreaterThan": 1000
}
},
"version": {
"tierToCool": {
"daysAfterCreationGreaterThan": 30
},
"tierToArchive": {
"daysAfterCreationGreaterThan": 90
},
"delete": {
"daysAfterCreationGreaterThan": 1000
}
}
}
}
}
]
},
"lastModifiedTime": "2018-06-08T02:53:39.0932539Z"
}
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -828,6 +828,12 @@
},
"StorageAccountSetManagementPolicy_LastAccessTimeBasedBlobActions": {
"$ref": "./examples/StorageAccountSetManagementPolicy_LastAccessTimeBasedBlobActions.json"
},
"StorageAccountSetManagementPolicyWithSnapshotAndVersion": {
"$ref": "./examples/StorageAccountSetManagementPolicyWithSnapshotAndVersion.json"
},
"StorageAccountSetManagementPolicyForBlockAndAppendBlobs": {
"$ref": "./examples/StorageAccountSetManagementPolicyForBlockAndAppendBlobs.json"
}
},
"parameters": [
Expand Down Expand Up @@ -3677,7 +3683,7 @@
"items": {
"type": "string"
},
"description": "An array of predefined enum values. Only blockBlob is supported."
"description": "An array of predefined enum values. Currently blockBlob supports all tiering and delete actions. Only delete actions are supported for appendBlob."
},
"blobIndexMatch": {
"type": "array",
Expand Down Expand Up @@ -3727,6 +3733,10 @@
"snapshot": {
"$ref": "#/definitions/ManagementPolicySnapShot",
"description": "The management policy action for snapshot"
},
"version": {
"$ref": "#/definitions/ManagementPolicyVersion",
"description": "The management policy action for version"
}
},
"description": "Actions are applied to the filtered blobs when the execution condition is met."
Expand Down Expand Up @@ -3754,13 +3764,38 @@
},
"ManagementPolicySnapShot": {
"properties": {
"tierToCool": {
"$ref": "#/definitions/DateAfterCreation",
"description": "The function to tier blob snapshot to cool storage. Support blob snapshot currently at Hot tier"
},
"tierToArchive": {
"$ref": "#/definitions/DateAfterCreation",
"description": "The function to tier blob snapshot to archive storage. Support blob snapshot currently at Hot or Cool tier"
},
"delete": {
"$ref": "#/definitions/DateAfterCreation",
"description": "The function to delete the blob snapshot"
}
},
"description": "Management policy action for snapshot."
},
"ManagementPolicyVersion": {
"properties": {
"tierToCool": {
"$ref": "#/definitions/DateAfterCreation",
"description": "The function to tier blob version to cool storage. Support blob version currently at Hot tier"
},
"tierToArchive": {
"$ref": "#/definitions/DateAfterCreation",
"description": "The function to tier blob version to archive storage. Support blob version currently at Hot or Cool tier"
},
"delete": {
"$ref": "#/definitions/DateAfterCreation",
"description": "The function to delete the blob version"
}
},
"description": "Management policy action for blob version."
},
"DateAfterModification": {
"properties": {
"daysAfterModificationGreaterThan": {
Expand All @@ -3776,7 +3811,7 @@
"description": "Value indicating the age in days after last blob access. This property can only be used in conjunction with last access time tracking policy"
}
},
"description": "Object to define the number of days after last modification."
"description": "Object to define the number of days after object last modification Or last access. Properties daysAfterModificationGreaterThan and daysAfterLastAccessTimeGreaterThan are mutually exclusive."
},
"DateAfterCreation": {
"properties": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,9 @@
"x-ms-examples": {
"PutBlobServices": {
"$ref": "./examples/BlobServicesPut.json"
},
"BlobServicesPutLastAccessTimeBasedTracking": {
"$ref": "./examples/BlobServicesPutLastAccessTimeBasedTracking.json"
}
},
"description": "Sets the properties of a storage account’s Blob service, including properties for Storage Analytics and CORS (Cross-Origin Resource Sharing) rules. ",
Expand Down Expand Up @@ -1204,6 +1207,10 @@
"containerDeleteRetentionPolicy": {
"$ref": "./common.json#/definitions/DeleteRetentionPolicy",
"description": "The blob service properties for container soft delete."
},
"lastAccessTimeTrackingPolicy": {
"$ref": "#/definitions/LastAccessTimeTrackingPolicy",
"description": "The blob service property to configure last access time based tracking policy."
}
},
"x-ms-client-flatten": true,
Expand Down Expand Up @@ -1274,6 +1281,41 @@
],
"description": "The blob service properties for blob restore policy"
},
"LastAccessTimeTrackingPolicy": {
"properties": {
"enable": {
"type": "boolean",
"description": "When set to true last access time based tracking is enabled."
},
"name": {
"type": "string",
"description": "Name of the policy. The valid value is AccessTimeTracking. This field is currently read only",
"enum": [
"AccessTimeTracking"
],
"x-ms-enum": {
"name": "name",
"modelAsString": true
}
},
"trackingGranularityInDays": {
"type": "integer",
"format": "int32",
"description": "The field specifies blob object tracking granularity in days, typically how often the blob object should be tracked.This field is currently read only with value as 1"
},
"blobType": {
"type": "array",
"items": {
"type": "string"
},
"description": "An array of predefined supported blob types. Only blockBlob is the supported value. This field is currently read only"
}
},
"required": [
"enable"
],
"description": "The blob service properties for Last access time based tracking policy."
},
"LeaseContainerRequest": {
"properties": {
"action": {
Expand Down
Loading