az stream-analytics input
Note
This reference is part of the stream-analytics extension for the Azure CLI (version 2.15.0 or higher). The extension will automatically install the first time you run an az stream-analytics input command. Learn more about extensions.
Manage input with stream analytics.
Commands
Name | Description | Type | Status |
---|---|---|---|
az stream-analytics input create |
Create an input or replaces an already existing input under an existing streaming job. |
Extension | GA |
az stream-analytics input delete |
Delete an input from the streaming job. |
Extension | GA |
az stream-analytics input list |
List all of the inputs under the specified streaming job. |
Extension | GA |
az stream-analytics input show |
Get details about the specified input. |
Extension | GA |
az stream-analytics input test |
Test whether an input’s datasource is reachable and usable by the Azure Stream Analytics service. |
Extension | GA |
az stream-analytics input update |
Update an existing input under an existing streaming job. This can be used to partially update (ie. update one or two properties) an input without affecting the rest the job or input definition. |
Extension | GA |
az stream-analytics input wait |
Place the CLI in a waiting state until a condition of the stream-analytics input is met. |
Extension | GA |
az stream-analytics input create
Create an input or replaces an already existing input under an existing streaming job.
az stream-analytics input create --input-name
--job-name
--resource-group
[--if-match]
[--if-none-match]
[--properties]
Examples
Create a reference blob input with CSV serialization
az stream-analytics input create --properties "{\"type\":\"Reference\",\"datasource\":{\"type\":\"Microsoft.Storage/Blob\",\"properties\":{\"container\":\"state\",\"dateFormat\":\"yyyy/MM/dd\",\"pathPattern\":\"{date}/{time}\",\"storageAccounts\":[{\"accountKey\":\"someAccountKey==\",\"accountName\":\"someAccountName\"}],\"timeFormat\":\"HH\"}},\"serialization\":{\"type\":\"Csv\",\"properties\":{\"encoding\":\"UTF8\",\"fieldDelimiter\":\",\"}}}" --input-name "input7225" --job-name "sj9597" --resource-group "sjrg8440"
Create a stream Event Hub input with JSON serialization
az stream-analytics input create --properties "{\"type\":\"Stream\",\"datasource\":{\"type\":\"Microsoft.ServiceBus/EventHub\",\"properties\":{\"consumerGroupName\":\"sdkconsumergroup\",\"eventHubName\":\"sdkeventhub\",\"serviceBusNamespace\":\"sdktest\",\"sharedAccessPolicyKey\":\"someSharedAccessPolicyKey==\",\"sharedAccessPolicyName\":\"RootManageSharedAccessKey\"}},\"serialization\":{\"type\":\"Json\",\"properties\":{\"encoding\":\"UTF8\"}}}" --input-name "input7425" --job-name "sj197" --resource-group "sjrg3139"
Create a stream IoT Hub input with Avro serialization
az stream-analytics input create --properties "{\"type\":\"Stream\",\"datasource\":{\"type\":\"Microsoft.Devices/IotHubs\",\"properties\":{\"consumerGroupName\":\"sdkconsumergroup\",\"endpoint\":\"messages/events\",\"iotHubNamespace\":\"iothub\",\"sharedAccessPolicyKey\":\"sharedAccessPolicyKey=\",\"sharedAccessPolicyName\":\"owner\"}},\"serialization\":{\"type\":\"Avro\"}}" --input-name "input7970" --job-name "sj9742" --resource-group "sjrg3467"
Create a stream blob input with CSV serialization
az stream-analytics input create --properties "{\"type\":\"Stream\",\"datasource\":{\"type\":\"Microsoft.Storage/Blob\",\"properties\":{\"container\":\"state\",\"dateFormat\":\"yyyy/MM/dd\",\"pathPattern\":\"{date}/{time}\",\"sourcePartitionCount\":16,\"storageAccounts\":[{\"accountKey\":\"someAccountKey==\",\"accountName\":\"someAccountName\"}],\"timeFormat\":\"HH\"}},\"serialization\":{\"type\":\"Csv\",\"properties\":{\"encoding\":\"UTF8\",\"fieldDelimiter\":\",\"}}}" --input-name "input8899" --job-name "sj6695" --resource-group "sjrg8161"
Required Parameters
The name of the input.
The name of the streaming job.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Optional Parameters
The ETag of the input. Omit this value to always overwrite the current input. Specify the last-seen ETag value to prevent accidentally overwriting concurrent changes.
Set to '*' to allow a new input to be created, but to prevent updating an existing input. Other values will result in a 412 Pre-condition Failed response.
The properties that are associated with an input. Required on PUT (CreateOrReplace) requests. Expected value: json-string/json-file/@json-file.
Global Parameters
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Increase logging verbosity. Use --debug for full debug logs.
az stream-analytics input delete
Delete an input from the streaming job.
az stream-analytics input delete --input-name
--job-name
--resource-group
[--yes]
Examples
Delete an input
az stream-analytics input delete --input-name "input7225" --job-name "sj9597" --resource-group "sjrg8440"
Required Parameters
The name of the input.
The name of the streaming job.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Optional Parameters
Do not prompt for confirmation.
Global Parameters
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Increase logging verbosity. Use --debug for full debug logs.
az stream-analytics input list
List all of the inputs under the specified streaming job.
az stream-analytics input list --job-name
--resource-group
[--select]
Examples
List all inputs in a streaming job
az stream-analytics input list --job-name "sj9597" --resource-group "sjrg8440"
List all inputs in a streaming job and include diagnostic information using the $select OData query parameter
az stream-analytics input list --select "*" --job-name "sj7804" --resource-group "sjrg3276"
Required Parameters
The name of the streaming job.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Optional Parameters
The $select OData query parameter. This is a comma-separated list of structural properties to include in the response, or "" to include all properties. By default, all properties are returned except diagnostics. Currently only accepts '' as a valid value.
Global Parameters
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Increase logging verbosity. Use --debug for full debug logs.
az stream-analytics input show
Get details about the specified input.
az stream-analytics input show --input-name
--job-name
--resource-group
Examples
Get a reference blob input with CSV serialization
az stream-analytics input show --input-name "input7225" --job-name "sj9597" --resource-group "sjrg8440"
Get a stream Event Hub input with JSON serialization
az stream-analytics input show --input-name "input7425" --job-name "sj197" --resource-group "sjrg3139"
Get a stream IoT Hub input with Avro serialization
az stream-analytics input show --input-name "input7970" --job-name "sj9742" --resource-group "sjrg3467"
Get a stream blob input with CSV serialization
az stream-analytics input show --input-name "input8899" --job-name "sj6695" --resource-group "sjrg8161"
Required Parameters
The name of the input.
The name of the streaming job.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Global Parameters
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Increase logging verbosity. Use --debug for full debug logs.
az stream-analytics input test
Test whether an input’s datasource is reachable and usable by the Azure Stream Analytics service.
az stream-analytics input test --input-name
--job-name
--resource-group
[--no-wait]
[--properties]
Examples
Test the connection for an input
az stream-analytics input test --input-name "input7225" --job-name "sj9597" --resource-group "sjrg8440"
Required Parameters
The name of the input.
The name of the streaming job.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Optional Parameters
Do not wait for the long-running operation to finish.
The properties that are associated with an input. Required on PUT (CreateOrReplace) requests. Expected value: json-string/json-file/@json-file.
Global Parameters
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Increase logging verbosity. Use --debug for full debug logs.
az stream-analytics input update
Update an existing input under an existing streaming job. This can be used to partially update (ie. update one or two properties) an input without affecting the rest the job or input definition.
az stream-analytics input update --input-name
--job-name
--resource-group
[--if-match]
[--properties]
Examples
Update a reference blob input
az stream-analytics input update --properties "{\"type\":\"Reference\",\"datasource\":{\"type\":\"Microsoft.Storage/Blob\",\"properties\":{\"container\":\"differentContainer\"}},\"serialization\":{\"type\":\"Csv\",\"properties\":{\"encoding\":\"UTF8\",\"fieldDelimiter\":\"|\"}}}" --input-name "input7225" --job-name "sj9597" --resource-group "sjrg8440"
Update a stream Event Hub input
az stream-analytics input update --properties "{\"type\":\"Stream\",\"datasource\":{\"type\":\"Microsoft.ServiceBus/EventHub\",\"properties\":{\"consumerGroupName\":\"differentConsumerGroupName\"}},\"serialization\":{\"type\":\"Avro\"}}" --input-name "input7425" --job-name "sj197" --resource-group "sjrg3139"
Update a stream IoT Hub input
az stream-analytics input update --properties "{\"type\":\"Stream\",\"datasource\":{\"type\":\"Microsoft.Devices/IotHubs\",\"properties\":{\"endpoint\":\"messages/operationsMonitoringEvents\"}},\"serialization\":{\"type\":\"Csv\",\"properties\":{\"encoding\":\"UTF8\",\"fieldDelimiter\":\"|\"}}}" --input-name "input7970" --job-name "sj9742" --resource-group "sjrg3467"
Update a stream blob input
az stream-analytics input update --properties "{\"type\":\"Stream\",\"datasource\":{\"type\":\"Microsoft.Storage/Blob\",\"properties\":{\"sourcePartitionCount\":32}},\"serialization\":{\"type\":\"Csv\",\"properties\":{\"encoding\":\"UTF8\",\"fieldDelimiter\":\"|\"}}}" --input-name "input8899" --job-name "sj6695" --resource-group "sjrg8161"
Required Parameters
The name of the input.
The name of the streaming job.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Optional Parameters
The ETag of the input. Omit this value to always overwrite the current input. Specify the last-seen ETag value to prevent accidentally overwriting concurrent changes.
The properties that are associated with an input. Required on PUT (CreateOrReplace) requests. Expected value: json-string/json-file/@json-file.
Global Parameters
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Increase logging verbosity. Use --debug for full debug logs.
az stream-analytics input wait
Place the CLI in a waiting state until a condition of the stream-analytics input is met.
az stream-analytics input wait --input-name
--job-name
--resource-group
[--created]
[--custom]
[--deleted]
[--exists]
[--interval]
[--timeout]
[--updated]
Examples
Pause executing next line of CLI script until the stream-analytics input is successfully created.
az stream-analytics input wait --input-name "input8899" --job-name "sj6695" --resource-group "sjrg8161" --created
Required Parameters
The name of the input.
The name of the streaming job.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Optional Parameters
Wait until created with 'provisioningState' at 'Succeeded'.
Wait until the condition satisfies a custom JMESPath query. E.g. provisioningState!='InProgress', instanceView.statuses[?code=='PowerState/running'].
Wait until deleted.
Wait until the resource exists.
Polling interval in seconds.
Maximum wait in seconds.
Wait until updated with provisioningState at 'Succeeded'.
Global Parameters
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Increase logging verbosity. Use --debug for full debug logs.