tasks
Creates, updates, deletes, gets or lists a tasks
resource.
Overview
Name | tasks |
Type | Resource |
Id | azure.data_migration.tasks |
Fields
- vw_tasks
- tasks
Name | Datatype | Description |
---|---|---|
id | text | Resource ID. |
name | text | Resource name. |
client_data | text | field from the properties object |
commands | text | field from the properties object |
errors | text | field from the properties object |
etag | text | HTTP strong entity tag value. This is ignored if submitted. |
groupName | text | field from the properties object |
projectName | text | field from the properties object |
serviceName | text | field from the properties object |
state | text | field from the properties object |
subscriptionId | text | field from the properties object |
system_data | text | field from the properties object |
taskName | text | field from the properties object |
task_type | text | field from the properties object |
type | text | Resource type. |
Name | Datatype | Description |
---|---|---|
id | string | Resource ID. |
name | string | Resource name. |
etag | string | HTTP strong entity tag value. This is ignored if submitted. |
properties | object | Base class for all types of DMS (classic) task properties. If task is not supported by current client, this object is returned. |
systemData | object | |
type | string | Resource type. |
Methods
Name | Accessible by | Required Params | Description |
---|---|---|---|
get | SELECT | groupName, projectName, serviceName, subscriptionId, taskName | The tasks resource is a nested, proxy-only resource representing work performed by a DMS (classic) instance. The GET method retrieves information about a task. |
list | SELECT | groupName, projectName, serviceName, subscriptionId | The services resource is the top-level resource that represents the Azure Database Migration Service (classic). This method returns a list of tasks owned by a service resource. Some tasks may have a status of Unknown, which indicates that an error occurred while querying the status of that task. |
create_or_update | INSERT | groupName, projectName, serviceName, subscriptionId, taskName | The tasks resource is a nested, proxy-only resource representing work performed by a DMS (classic) instance. The PUT method creates a new task or updates an existing one, although since tasks have no mutable custom properties, there is little reason to update an existing one. |
delete | DELETE | groupName, projectName, serviceName, subscriptionId, taskName | The tasks resource is a nested, proxy-only resource representing work performed by a DMS (classic) instance. The DELETE method deletes a task, canceling it first if it's running. |
update | UPDATE | groupName, projectName, serviceName, subscriptionId, taskName | The tasks resource is a nested, proxy-only resource representing work performed by a DMS (classic) instance. The PATCH method updates an existing task, but since tasks have no mutable custom properties, there is little reason to do so. |
cancel | EXEC | groupName, projectName, serviceName, subscriptionId, taskName | The tasks resource is a nested, proxy-only resource representing work performed by a DMS (classic) instance. This method cancels a task if it's currently queued or running. |
command | EXEC | groupName, projectName, serviceName, subscriptionId, taskName, data__commandType | The tasks resource is a nested, proxy-only resource representing work performed by a DMS (classic) instance. This method executes a command on a running task. |
SELECT
examples
The services resource is the top-level resource that represents the Azure Database Migration Service (classic). This method returns a list of tasks owned by a service resource. Some tasks may have a status of Unknown, which indicates that an error occurred while querying the status of that task.
- vw_tasks
- tasks
SELECT
id,
name,
client_data,
commands,
errors,
etag,
groupName,
projectName,
serviceName,
state,
subscriptionId,
system_data,
taskName,
task_type,
type
FROM azure.data_migration.vw_tasks
WHERE groupName = '{{ groupName }}'
AND projectName = '{{ projectName }}'
AND serviceName = '{{ serviceName }}'
AND subscriptionId = '{{ subscriptionId }}';
SELECT
id,
name,
etag,
properties,
systemData,
type
FROM azure.data_migration.tasks
WHERE groupName = '{{ groupName }}'
AND projectName = '{{ projectName }}'
AND serviceName = '{{ serviceName }}'
AND subscriptionId = '{{ subscriptionId }}';
INSERT
example
Use the following StackQL query and manifest file to create a new tasks
resource.
- All Properties
- Manifest
/*+ create */
INSERT INTO azure.data_migration.tasks (
groupName,
projectName,
serviceName,
subscriptionId,
taskName,
etag,
properties
)
SELECT
'{{ groupName }}',
'{{ projectName }}',
'{{ serviceName }}',
'{{ subscriptionId }}',
'{{ taskName }}',
'{{ etag }}',
'{{ properties }}'
;
- name: your_resource_model_name
props:
- name: etag
value: string
- name: properties
value:
- name: taskType
value: string
- name: errors
value:
- - name: code
value: string
- name: message
value: string
- name: details
value:
- - name: code
value: string
- name: message
value: string
- name: details
value:
- - name: code
value: string
- name: message
value: string
- name: details
value:
- - name: code
value: string
- name: message
value: string
- name: details
value:
- - name: code
value: string
- name: message
value: string
- name: details
value:
- - name: code
value: string
- name: message
value: string
- name: details
value:
- - name: code
value: string
- name: message
value: string
- name: details
value:
- - name: code
value: string
- name: message
value: string
- name: details
value:
- - name: code
value: string
- name: message
value: string
- name: details
value:
- []
- name: state
value: string
- name: commands
value:
- - name: commandType
value: string
- name: errors
value:
- - name: code
value: string
- name: message
value: string
- name: details
value:
- - name: code
value: string
- name: message
value: string
- name: details
value:
- - name: code
value: string
- name: message
value: string
- name: details
value:
- - name: code
value: string
- name: message
value: string
- name: details
value:
- - name: code
value: string
- name: message
value: string
- name: details
value:
- - name: code
value: string
- name: message
value: string
- name: details
value:
- - name: code
value: string
- name: message
value: string
- name: details
value:
- - name: code
value: string
- name: message
value: string
- name: details
value:
- []
- name: state
value: string
- name: clientData
value: object
- name: systemData
value:
- name: createdBy
value: string
- name: createdByType
value: string
- name: createdAt
value: string
- name: lastModifiedBy
value: string
- name: lastModifiedByType
value: string
- name: lastModifiedAt
value: string
- name: id
value: string
- name: name
value: string
- name: type
value: string
UPDATE
example
Updates a tasks
resource.
/*+ update */
UPDATE azure.data_migration.tasks
SET
etag = '{{ etag }}',
properties = '{{ properties }}'
WHERE
groupName = '{{ groupName }}'
AND projectName = '{{ projectName }}'
AND serviceName = '{{ serviceName }}'
AND subscriptionId = '{{ subscriptionId }}'
AND taskName = '{{ taskName }}';
DELETE
example
Deletes the specified tasks
resource.
/*+ delete */
DELETE FROM azure.data_migration.tasks
WHERE groupName = '{{ groupName }}'
AND projectName = '{{ projectName }}'
AND serviceName = '{{ serviceName }}'
AND subscriptionId = '{{ subscriptionId }}'
AND taskName = '{{ taskName }}';