transformations
Creates, updates, deletes, gets or lists a transformations resource.
Overview
| Name | transformations |
| Type | Resource |
| Id | azure.stream_analytics.transformations |
Fields
The following fields are returned by SELECT queries:
- get
| Name | Datatype | Description |
|---|---|---|
id | string | Resource Id. |
name | string | Resource name. |
etag | string | The current entity tag for the transformation. This is an opaque string. You can use it to detect whether the resource has changed between requests. You can also use it in the If-Match or If-None-Match headers for write operations for optimistic concurrency. |
query | string | Specifies the query that will be run in the streaming job. You can learn more about the Stream Analytics Query Language (SAQL) here: https://msdn.microsoft.com/library/azure/dn834998 . Required on PUT (CreateOrReplace) requests. |
streamingUnits | integer | Specifies the number of streaming units that the streaming job uses. |
type | string | Resource type. |
validStreamingUnits | array | Specifies the valid streaming units a streaming job can scale to. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | resource_group_name, job_name, transformation_name, subscription_id | Gets details about the specified transformation. | |
create_or_replace | insert | resource_group_name, job_name, transformation_name, subscription_id | If-Match, If-None-Match | Creates a transformation or replaces an already existing transformation under an existing streaming job. |
update | update | resource_group_name, job_name, transformation_name, subscription_id | If-Match | Updates an existing transformation under an existing streaming job. This can be used to partially update (ie. update one or two properties) a transformation without affecting the rest the job or transformation definition. |
create_or_replace | replace | resource_group_name, job_name, transformation_name, subscription_id | If-Match, If-None-Match | Creates a transformation or replaces an already existing transformation under an existing streaming job. |
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.
| Name | Datatype | Description |
|---|---|---|
job_name | string | The name of the streaming job. Required. |
resource_group_name | string | The name of the resource group. The name is case insensitive. Required. |
subscription_id | string | |
transformation_name | string | The name of the transformation. Required. |
If-Match | string | The ETag of the transformation. Omit this value to always overwrite the current transformation. Specify the last-seen ETag value to prevent accidentally overwriting concurrent changes. Default value is None. |
If-None-Match | string | Set to '*' to allow a new transformation to be created, but to prevent updating an existing transformation. Other values will result in a 412 Pre-condition Failed response. Default value is None. |
SELECT examples
- get
Gets details about the specified transformation.
SELECT
id,
name,
etag,
query,
streamingUnits,
type,
validStreamingUnits
FROM azure.stream_analytics.transformations
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND job_name = '{{ job_name }}' -- required
AND transformation_name = '{{ transformation_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;
INSERT examples
- create_or_replace
- Manifest
Creates a transformation or replaces an already existing transformation under an existing streaming job.
INSERT INTO azure.stream_analytics.transformations (
name,
properties,
resource_group_name,
job_name,
transformation_name,
subscription_id,
If-Match,
If-None-Match
)
SELECT
'{{ name }}',
'{{ properties }}',
'{{ resource_group_name }}',
'{{ job_name }}',
'{{ transformation_name }}',
'{{ subscription_id }}',
'{{ If-Match }}',
'{{ If-None-Match }}'
RETURNING
id,
name,
properties,
type
;
# Description fields are for documentation purposes
- name: transformations
props:
- name: resource_group_name
value: "{{ resource_group_name }}"
description: Required parameter for the transformations resource.
- name: job_name
value: "{{ job_name }}"
description: Required parameter for the transformations resource.
- name: transformation_name
value: "{{ transformation_name }}"
description: Required parameter for the transformations resource.
- name: subscription_id
value: "{{ subscription_id }}"
description: Required parameter for the transformations resource.
- name: name
value: "{{ name }}"
description: |
Resource name.
- name: properties
value:
streamingUnits: {{ streamingUnits }}
validStreamingUnits:
- {{ validStreamingUnits }}
query: "{{ query }}"
- name: If-Match
value: "{{ If-Match }}"
description: The ETag of the transformation. Omit this value to always overwrite the current transformation. Specify the last-seen ETag value to prevent accidentally overwriting concurrent changes. Default value is None.
description: The ETag of the transformation. Omit this value to always overwrite the current transformation. Specify the last-seen ETag value to prevent accidentally overwriting concurrent changes. Default value is None.
- name: If-None-Match
value: "{{ If-None-Match }}"
description: Set to '*' to allow a new transformation to be created, but to prevent updating an existing transformation. Other values will result in a 412 Pre-condition Failed response. Default value is None.
description: Set to '*' to allow a new transformation to be created, but to prevent updating an existing transformation. Other values will result in a 412 Pre-condition Failed response. Default value is None.
UPDATE examples
- update
Updates an existing transformation under an existing streaming job. This can be used to partially update (ie. update one or two properties) a transformation without affecting the rest the job or transformation definition.
UPDATE azure.stream_analytics.transformations
SET
name = '{{ name }}',
properties = '{{ properties }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND job_name = '{{ job_name }}' --required
AND transformation_name = '{{ transformation_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
AND If-Match = '{{ If-Match}}'
RETURNING
id,
name,
properties,
type;
REPLACE examples
- create_or_replace
Creates a transformation or replaces an already existing transformation under an existing streaming job.
REPLACE azure.stream_analytics.transformations
SET
name = '{{ name }}',
properties = '{{ properties }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND job_name = '{{ job_name }}' --required
AND transformation_name = '{{ transformation_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
AND If-Match = '{{ If-Match}}'
AND If-None-Match = '{{ If-None-Match}}'
RETURNING
id,
name,
properties,
type;