azureblog.co.uk
← cd ~/roles
// roles/azure · analytics

Stream Analytics Query TesterAzure built-in role

Lets you perform query testing without creating a stream analytics job first

Role ID1ec5b3c1-b17e-4e25-8312-2acb3c3c5abf
CategoryAnalytics
Actions4
Data actions0

What it can do

PermissionWhat it allows
Microsoft.StreamAnalytics/locations/TestQuery/actionTest Query for Stream Analytics Resource Provider
Microsoft.StreamAnalytics/locations/OperationResults/readRead Stream Analytics Operation Result
Microsoft.StreamAnalytics/locations/SampleInput/actionSample Input for Stream Analytics Resource Provider
Microsoft.StreamAnalytics/locations/CompileQuery/actionCompile Query for Stream Analytics Resource Provider

Assign it

Scope it as tightly as you can: a resource or resource group rather than the whole subscription.

azure cli
az role assignment create \
  --assignee "jane.doe@contoso.com" \
  --role "Stream Analytics Query Tester" \
  --scope "/subscriptions/<subscription id>/resourceGroups/<resource group>"
powershell3 lines
New-AzRoleAssignment -SignInName "jane.doe@contoso.com" `
  -RoleDefinitionName "Stream Analytics Query Tester" `
  -Scope "/subscriptions/<subscription id>/resourceGroups/<resource group>"
bicep7 lines
resource assignment 'Microsoft.Authorization/roleAssignments@2022-04-01' = {
  name: guid(resourceGroup().id, principalId, '1ec5b3c1-b17e-4e25-8312-2acb3c3c5abf')
  properties: {
    roleDefinitionId: subscriptionResourceId('Microsoft.Authorization/roleDefinitions', '1ec5b3c1-b17e-4e25-8312-2acb3c3c5abf')
    principalId: principalId
  }
}

Who already has it?

kql · azure resource graph
authorizationresources
| where type == "microsoft.authorization/roleassignments"
| where tostring(properties.roleDefinitionId) endswith "1ec5b3c1-b17e-4e25-8312-2acb3c3c5abf"
| project principalId = tostring(properties.principalId), principalType = tostring(properties.principalType), scope = tostring(properties.scope)

Other analytics roles

Find the smallest role for a task →