Skip to main content

storage_tasks

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

Overview

Namestorage_tasks
TypeResource
Idazure.storageactions.storage_tasks

Fields

NameDatatypeDescription
descriptiontextfield from the properties object
actiontextfield from the properties object
creation_time_in_utctextfield from the properties object
enabledtextfield from the properties object
identitytextManaged service identity (system assigned and/or user assigned identities)
locationtextThe geo-location where the resource lives
provisioning_statetextfield from the properties object
resourceGroupNametextfield from the properties object
storageTaskNametextfield from the properties object
subscriptionIdtextfield from the properties object
tagstextResource tags.
task_versiontextfield from the properties object

Methods

NameAccessible byRequired ParamsDescription
getSELECTresourceGroupName, storageTaskName, subscriptionIdGet the storage task properties
list_by_resource_groupSELECTresourceGroupName, subscriptionIdLists all the storage tasks available under the given resource group.
list_by_subscriptionSELECTsubscriptionIdLists all the storage tasks available under the subscription.
createINSERTresourceGroupName, storageTaskName, subscriptionId, data__identity, data__propertiesAsynchronously creates a new storage task resource with the specified parameters. If a storage task is already created and a subsequent create request is issued with different properties, the storage task properties will be updated. If a storage task is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
deleteDELETEresourceGroupName, storageTaskName, subscriptionIdDelete the storage task resource.
updateUPDATEresourceGroupName, storageTaskName, subscriptionIdUpdate storage task properties
preview_actionsEXEClocation, subscriptionId, data__propertiesRuns the input conditions against input object metadata properties and designates matched objects in response.

SELECT examples

Lists all the storage tasks available under the subscription.

SELECT
description,
action,
creation_time_in_utc,
enabled,
identity,
location,
provisioning_state,
resourceGroupName,
storageTaskName,
subscriptionId,
tags,
task_version
FROM azure.storageactions.vw_storage_tasks
WHERE subscriptionId = '{{ subscriptionId }}';

INSERT example

Use the following StackQL query and manifest file to create a new storage_tasks resource.

/*+ create */
INSERT INTO azure.storageactions.storage_tasks (
resourceGroupName,
storageTaskName,
subscriptionId,
data__identity,
data__properties,
identity,
properties,
tags,
location
)
SELECT
'{{ resourceGroupName }}',
'{{ storageTaskName }}',
'{{ subscriptionId }}',
'{{ data__identity }}',
'{{ data__properties }}',
'{{ identity }}',
'{{ properties }}',
'{{ tags }}',
'{{ location }}'
;

UPDATE example

Updates a storage_tasks resource.

/*+ update */
UPDATE azure.storageactions.storage_tasks
SET
identity = '{{ identity }}',
tags = '{{ tags }}',
properties = '{{ properties }}'
WHERE
resourceGroupName = '{{ resourceGroupName }}'
AND storageTaskName = '{{ storageTaskName }}'
AND subscriptionId = '{{ subscriptionId }}';

DELETE example

Deletes the specified storage_tasks resource.

/*+ delete */
DELETE FROM azure.storageactions.storage_tasks
WHERE resourceGroupName = '{{ resourceGroupName }}'
AND storageTaskName = '{{ storageTaskName }}'
AND subscriptionId = '{{ subscriptionId }}';