blob_containers
Creates, updates, deletes, gets or lists a blob_containers
resource.
Overview
Name | blob_containers |
Type | Resource |
Id | azure.storage.blob_containers |
Fields
- vw_blob_containers
- blob_containers
Name | Datatype | Description |
---|---|---|
accountName | text | field from the properties object |
containerName | text | field from the properties object |
default_encryption_scope | text | field from the properties object |
deleted | text | field from the properties object |
deleted_time | text | field from the properties object |
deny_encryption_scope_override | text | field from the properties object |
enable_nfs_v3_all_squash | text | field from the properties object |
enable_nfs_v3_root_squash | text | field from the properties object |
etag | text | Resource Etag. |
has_immutability_policy | text | field from the properties object |
has_legal_hold | text | field from the properties object |
immutability_policy | text | field from the properties object |
immutable_storage_with_versioning | text | field from the properties object |
last_modified_time | text | field from the properties object |
lease_duration | text | field from the properties object |
lease_state | text | field from the properties object |
lease_status | text | field from the properties object |
legal_hold | text | field from the properties object |
metadata | text | field from the properties object |
public_access | text | field from the properties object |
remaining_retention_days | text | field from the properties object |
resourceGroupName | text | field from the properties object |
subscriptionId | text | field from the properties object |
version | text | field from the properties object |
Name | Datatype | Description |
---|---|---|
etag | string | Resource Etag. |
properties | object | The properties of a container. |
Methods
Name | Accessible by | Required Params | Description |
---|---|---|---|
get | SELECT | accountName, containerName, resourceGroupName, subscriptionId | Gets properties of a specified container. |
list | SELECT | accountName, resourceGroupName, subscriptionId | Lists all containers and does not support a prefix like data plane. Also SRP today does not return continuation token. |
create | INSERT | accountName, containerName, resourceGroupName, subscriptionId | Creates a new container under the specified account as described by request body. The container resource includes metadata and properties for that container. It does not include a list of the blobs contained by the container. |
delete | DELETE | accountName, containerName, resourceGroupName, subscriptionId | Deletes specified container under its account. |
update | UPDATE | accountName, containerName, resourceGroupName, subscriptionId | Updates container properties as specified in request body. Properties not mentioned in the request will be unchanged. Update fails if the specified container doesn't already exist. |
clear_legal_hold | EXEC | accountName, containerName, resourceGroupName, subscriptionId, data__tags | Clears legal hold tags. Clearing the same or non-existent tag results in an idempotent operation. ClearLegalHold clears out only the specified tags in the request. |
extend_immutability_policy | EXEC | If-Match, accountName, containerName, resourceGroupName, subscriptionId, data__properties | Extends the immutabilityPeriodSinceCreationInDays of a locked immutabilityPolicy. The only action allowed on a Locked policy will be this action. ETag in If-Match is required for this operation. |
lease | EXEC | accountName, containerName, resourceGroupName, subscriptionId, data__action | The Lease Container operation establishes and manages a lock on a container for delete operations. The lock duration can be 15 to 60 seconds, or can be infinite. |
lock_immutability_policy | EXEC | If-Match, accountName, containerName, resourceGroupName, subscriptionId | Sets the ImmutabilityPolicy to Locked state. The only action allowed on a Locked policy is ExtendImmutabilityPolicy action. ETag in If-Match is required for this operation. |
object_level_worm | EXEC | accountName, containerName, resourceGroupName, subscriptionId | This operation migrates a blob container from container level WORM to object level immutability enabled container. Prerequisites require a container level immutability policy either in locked or unlocked state, Account level versioning must be enabled and there should be no Legal hold on the container. |
set_legal_hold | EXEC | accountName, containerName, resourceGroupName, subscriptionId, data__tags | Sets legal hold tags. Setting the same tag results in an idempotent operation. SetLegalHold follows an append pattern and does not clear out the existing tags that are not specified in the request. |
SELECT
examples
Lists all containers and does not support a prefix like data plane. Also SRP today does not return continuation token.
- vw_blob_containers
- blob_containers
SELECT
accountName,
containerName,
default_encryption_scope,
deleted,
deleted_time,
deny_encryption_scope_override,
enable_nfs_v3_all_squash,
enable_nfs_v3_root_squash,
etag,
has_immutability_policy,
has_legal_hold,
immutability_policy,
immutable_storage_with_versioning,
last_modified_time,
lease_duration,
lease_state,
lease_status,
legal_hold,
metadata,
public_access,
remaining_retention_days,
resourceGroupName,
subscriptionId,
version
FROM azure.storage.vw_blob_containers
WHERE accountName = '{{ accountName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';
SELECT
etag,
properties
FROM azure.storage.blob_containers
WHERE accountName = '{{ accountName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';
INSERT
example
Use the following StackQL query and manifest file to create a new blob_containers
resource.
- All Properties
- Manifest
/*+ create */
INSERT INTO azure.storage.blob_containers (
accountName,
containerName,
resourceGroupName,
subscriptionId,
properties
)
SELECT
'{{ accountName }}',
'{{ containerName }}',
'{{ resourceGroupName }}',
'{{ subscriptionId }}',
'{{ properties }}'
;
- name: your_resource_model_name
props:
- name: properties
value:
- name: version
value: string
- name: deleted
value: boolean
- name: deletedTime
value: string
- name: remainingRetentionDays
value: integer
- name: defaultEncryptionScope
value: string
- name: denyEncryptionScopeOverride
value: boolean
- name: publicAccess
value: string
- name: lastModifiedTime
value: string
- name: leaseStatus
value: string
- name: leaseState
value: string
- name: leaseDuration
value: string
- name: metadata
value: object
- name: immutabilityPolicy
value:
- name: properties
value:
- name: immutabilityPeriodSinceCreationInDays
value: integer
- name: state
value: string
- name: allowProtectedAppendWrites
value: boolean
- name: allowProtectedAppendWritesAll
value: boolean
- name: etag
value: string
- name: updateHistory
value:
- - name: update
value: string
- name: immutabilityPeriodSinceCreationInDays
value: integer
- name: timestamp
value: string
- name: objectIdentifier
value: string
- name: tenantId
value: string
- name: upn
value: string
- name: allowProtectedAppendWrites
value: boolean
- name: allowProtectedAppendWritesAll
value: boolean
- name: legalHold
value:
- name: hasLegalHold
value: boolean
- name: tags
value:
- - name: tag
value: string
- name: timestamp
value: string
- name: objectIdentifier
value: string
- name: tenantId
value: string
- name: upn
value: string
- name: protectedAppendWritesHistory
value:
- name: allowProtectedAppendWritesAll
value: boolean
- name: timestamp
value: string
- name: hasLegalHold
value: boolean
- name: hasImmutabilityPolicy
value: boolean
- name: immutableStorageWithVersioning
value:
- name: enabled
value: boolean
- name: timeStamp
value: string
- name: migrationState
value: string
- name: enableNfsV3RootSquash
value: boolean
- name: enableNfsV3AllSquash
value: boolean
- name: etag
value: string
UPDATE
example
Updates a blob_containers
resource.
/*+ update */
UPDATE azure.storage.blob_containers
SET
properties = '{{ properties }}'
WHERE
accountName = '{{ accountName }}'
AND containerName = '{{ containerName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';
DELETE
example
Deletes the specified blob_containers
resource.
/*+ delete */
DELETE FROM azure.storage.blob_containers
WHERE accountName = '{{ accountName }}'
AND containerName = '{{ containerName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';