Skip to main content

move_collections

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

Overview

Namemove_collections
TypeResource
Idazure.resource_mover.move_collections

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
idstringFully qualified resource Id for the resource.
namestringThe name of the resource
etagstringThe etag of the resource.
identityobjectDefines the MSI properties of the Move Collection.
locationstringThe geo-location where the resource lives.
propertiesobjectDefines the move collection properties.
systemDataobjectMetadata pertaining to creation and last modification of the resource.
tagsobjectResource tags.
typestringThe type of the resource.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectsubscriptionId, resourceGroupName, moveCollectionNameapi-versionGets the move collection.
createinsertsubscriptionId, resourceGroupName, moveCollectionNameapi-versionCreates or updates a move collection.
updateupdatesubscriptionId, resourceGroupName, moveCollectionNameapi-versionUpdates a move collection.
deletedeletesubscriptionId, resourceGroupName, moveCollectionNameapi-versionDeletes a move collection.
prepareexecsubscriptionId, resourceGroupName, moveCollectionName, moveResourcesapi-versionInitiates prepare for the set of resources included in the request body. The prepare operation is on the moveResources that are in the moveState 'PreparePending' or 'PrepareFailed', on a successful completion the moveResource moveState do a transition to MovePending. To aid the user to prerequisite the operation the client can call operation with validateOnly property set to true.
initiate_moveexecsubscriptionId, resourceGroupName, moveCollectionName, moveResourcesapi-versionMoves the set of resources included in the request body. The move operation is triggered after the moveResources are in the moveState 'MovePending' or 'MoveFailed', on a successful completion the moveResource moveState do a transition to CommitPending. To aid the user to prerequisite the operation the client can call operation with validateOnly property set to true.
commitexecsubscriptionId, resourceGroupName, moveCollectionName, moveResourcesapi-versionCommits the set of resources included in the request body. The commit operation is triggered on the moveResources in the moveState 'CommitPending' or 'CommitFailed', on a successful completion the moveResource moveState do a transition to Committed. To aid the user to prerequisite the operation the client can call operation with validateOnly property set to true.
discardexecsubscriptionId, resourceGroupName, moveCollectionName, moveResourcesapi-versionDiscards the set of resources included in the request body. The discard operation is triggered on the moveResources in the moveState 'CommitPending' or 'DiscardFailed', on a successful completion the moveResource moveState do a transition to MovePending. To aid the user to prerequisite the operation the client can call operation with validateOnly property set to true.
resolve_dependenciesexecsubscriptionId, resourceGroupName, moveCollectionNameapi-versionComputes, resolves and validate the dependencies of the moveResources in the move collection.
bulk_removeexecsubscriptionId, resourceGroupName, moveCollectionNameapi-versionRemoves the set of move resources included in the request body from move collection. The orchestration is done by service. To aid the user to prerequisite the operation the client can call operation with validateOnly property set to true.

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
moveCollectionNamestring
resourceGroupNamestring
subscriptionIdstringThe Subscription ID.
api-versionstringClient Api Version.

SELECT examples

Gets the move collection.

SELECT
id,
name,
etag,
identity,
location,
properties,
systemData,
tags,
type
FROM azure.resource_mover.move_collections
WHERE subscriptionId = '{{ subscriptionId }}' -- required
AND resourceGroupName = '{{ resourceGroupName }}' -- required
AND moveCollectionName = '{{ moveCollectionName }}' -- required
AND api-version = '{{ api-version }}'
;

INSERT examples

Creates or updates a move collection.

INSERT INTO azure.resource_mover.move_collections (
data__tags,
data__location,
data__identity,
data__properties,
subscriptionId,
resourceGroupName,
moveCollectionName,
api-version
)
SELECT
'{{ tags }}',
'{{ location }}',
'{{ identity }}',
'{{ properties }}',
'{{ subscriptionId }}',
'{{ resourceGroupName }}',
'{{ moveCollectionName }}',
'{{ api-version }}'
RETURNING
id,
name,
etag,
identity,
location,
properties,
systemData,
tags,
type
;

UPDATE examples

Updates a move collection.

UPDATE azure.resource_mover.move_collections
SET
data__tags = '{{ tags }}',
data__identity = '{{ identity }}'
WHERE
subscriptionId = '{{ subscriptionId }}' --required
AND resourceGroupName = '{{ resourceGroupName }}' --required
AND moveCollectionName = '{{ moveCollectionName }}' --required
AND api-version = '{{ api-version}}'
RETURNING
id,
name,
etag,
identity,
location,
properties,
systemData,
tags,
type;

DELETE examples

Deletes a move collection.

DELETE FROM azure.resource_mover.move_collections
WHERE subscriptionId = '{{ subscriptionId }}' --required
AND resourceGroupName = '{{ resourceGroupName }}' --required
AND moveCollectionName = '{{ moveCollectionName }}' --required
AND api-version = '{{ api-version }}'
;

Lifecycle Methods

Initiates prepare for the set of resources included in the request body. The prepare operation is on the moveResources that are in the moveState 'PreparePending' or 'PrepareFailed', on a successful completion the moveResource moveState do a transition to MovePending. To aid the user to prerequisite the operation the client can call operation with validateOnly property set to true.

EXEC azure.resource_mover.move_collections.prepare 
@subscriptionId='{{ subscriptionId }}' --required,
@resourceGroupName='{{ resourceGroupName }}' --required,
@moveCollectionName='{{ moveCollectionName }}' --required,
@api-version='{{ api-version }}'
@@json=
'{
"validateOnly": {{ validateOnly }},
"moveResources": "{{ moveResources }}",
"moveResourceInputType": "{{ moveResourceInputType }}"
}'
;