Complete the code to create an Event Grid subscription that listens to events from a storage account.
az eventgrid event-subscription create --name mySub --source-resource-id /subscriptions/123/resourceGroups/myRG/providers/Microsoft.Storage/storageAccounts/myStorage [1] --endpoint https://myendpoint.com/api/events
The --endpoint-type webhook option specifies that the Event Grid subscription sends events to a web endpoint, which is common for event handlers.
Complete the code to create a Service Bus queue with a lock duration of 45 seconds.
az servicebus queue create --resource-group myRG --namespace-name myNamespace --name myQueue --lock-duration [1]The lock duration is specified in ISO 8601 duration format. PT45S means 45 seconds.
Fix the error in the code to send a message to a Service Bus queue using Azure CLI.
az servicebus queue send --resource-group myRG --namespace-name myNamespace --name myQueue --message-body [1]The message body must be enclosed in single quotes to be interpreted as a string by the CLI.
Fill both blanks to configure a Service Bus topic subscription with a SQL filter to receive only messages where the property 'priority' is 'high'.
az servicebus topic subscription create --resource-group myRG --namespace-name myNamespace --topic-name myTopic --name mySub --[1] "[2]"
The correct parameter is sql-filter and the SQL filter syntax uses a single equals sign for comparison.
Fill all three blanks to create an Event Grid subscription that filters events by subject prefix and sends them to a Service Bus queue.
az eventgrid event-subscription create --name mySub --source-resource-id /subscriptions/123/resourceGroups/myRG/providers/Microsoft.Storage/storageAccounts/myStorage --endpoint-type [1] --endpoint /subscriptions/123/resourceGroups/myRG/providers/Microsoft.ServiceBus/namespaces/myNamespace/queues/[2] --subject-begins-with [3]
The endpoint type for a Service Bus queue is queue. The endpoint specifies the queue name, and the subject filter uses the prefix path for blob container events.