AZ-204 Connect to and consume Azure services and third-party services • Complete Question Bank
Complete AZ-204 Connect to and consume Azure services and third-party services question bank — all 0 questions with answers and detailed explanations.
Drag a concept onto its matching description — or click a concept then click the description.
In-memory data store based on Redis
Content delivery network for static assets
Global HTTP load balancer and web application firewall
Regional HTTP load balancer with SSL termination
You run the following PowerShell script to upload a blob to Azure Storage:
```powershell $context = New-AzStorageContext -StorageAccountName 'mystorageaccount' -StorageAccountKey 'fakekey...' Set-AzStorageBlobContent -Context $context -Container 'mycontainer' -Blob 'myblob' -File 'This is the file content' ```
The script fails with an error.
Which part of the script is causing the failure?
Refer to the exhibit. ```powershell $connectionString = "DefaultEndpointsProtocol=https;AccountName=mystorageaccount;AccountKey=mykey;EndpointSuffix=core.windows.net" $container = "mycontainer" $blobName = "myblob.txt" $content = "Hello World" $ctx = New-AzStorageContext -ConnectionString $connectionString Set-AzStorageBlobContent -Context $ctx -Container $container -File $content -Blob $blobName ```
Refer to the exhibit.
```json
{
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"storageAccountName": {
"type": "string"
}
},
"resources": [
{
"type": "Microsoft.Storage/storageAccounts",
"apiVersion": "2021-09-01",
"name": "[parameters('storageAccountName')]",
"location": "[resourceGroup().location]",
"sku": {
"name": "Standard_LRS"
},
"kind": "StorageV2",
"properties": {
"supportsHttpsTrafficOnly": true
}
}
]
}```Drag steps to the numbered slots on the right, or tap a step then tap a slot.
Drag steps to the numbered slots on the right, or tap a step then tap a slot.
Drag a concept onto its matching description — or click a concept then click the description.
Git repositories for source control
CI/CD for building and deploying code
Agile project management with Kanban boards
Package management for Maven, npm, NuGet
Refer to the exhibit.
```json
{
"type": "Microsoft.Web/sites/config",
"apiVersion": "2022-03-01",
"name": "appsettings",
"properties": {
"MyApiEndpoint": "https://api.contoso.com",
"MyApiKey": "@Microsoft.KeyVault(SecretUri=https://myvault.vault.azure.net/secrets/MyApiKey/)"
}
}
```Refer to the exhibit. ```sql SELECT bin(TimeGenerated, 1h) AS TimeHour, ResourceProvider, AVG(Value) AS AvgValue FROM metrics WHERE TimeGenerated > ago(1d) GROUP BY bin(TimeGenerated, 1h), ResourceProvider | order by TimeHour asc ```
Refer to the exhibit.
```json
{
"properties": {
"description": "Allow access to storage account from specific virtual network",
"policyRule": {
"if": {
"field": "type",
"equals": "Microsoft.Storage/storageAccounts"
},
"then": {
"effect": "deny",
"details": {
"networkAcls": {
"defaultAction": "Deny",
"virtualNetworkRules": [
{
"id": "/subscriptions/sub-id/resourceGroups/rg/providers/Microsoft.Network/virtualNetworks/vnet1",
"action": "Allow"
}
]
}
}
}
}
}
}
```{
"type": "Microsoft.Web/sites/sourcecontrols",
"properties": {
"repoUrl": "https://github.com/contoso/app.git",
"branch": "main",
"isManualIntegration": false,
"gitHubActionConfiguration": {
"codeConfiguration": {
"runtimeStack": "dotnetcore|8.0",
"runtimeVersion": "8.0"
}
}
}
}{
"resources": [
{
"type": "Microsoft.ApiManagement/service/apis",
"apiVersion": "2022-08-01",
"name": "[concat(parameters('apimServiceName'), '/myapi')]",
"properties": {
"displayName": "My API",
"path": "myapi",
"protocols": ["https"],
"serviceUrl": "https://mybackend.azurewebsites.net",
"authenticationSettings": {
"oAuth2": {
"authorizationServerId": "auth-server-1",
"scope": "read write"
}
}
},
"dependsOn": [
"[resourceId('Microsoft.ApiManagement/service/authorizationServers', parameters('apimServiceName'), 'auth-server-1')]"
]
}
]
}{
"type": "Microsoft.CognitiveServices/accounts",
"apiVersion": "2023-05-01",
"name": "myopenai",
"location": "eastus",
"kind": "OpenAI",
"sku": {
"name": "S0"
},
"properties": {
"customSubDomainName": "myopenai",
"networkAcls": {
"defaultAction": "Deny",
"ipRules": [
{
"value": "203.0.113.0/24"
}
]
}
}
}Refer to the exhibit.
{
"type": "Microsoft.Network/networkSecurityGroups/securityRules",
"apiVersion": "2021-02-01",
"name": "DenyInternetOutbound",
"properties": {
"priority": 100,
"direction": "Outbound",
"access": "Deny",
"sourceAddressPrefixes": ["VirtualNetwork"],
"destinationAddressPrefixes": ["Internet"],
"destinationPortRanges": ["*"],
"protocol": "*",
"sourcePortRange": "*"
}
}Refer to the exhibit. az storage blob upload \ --account-name mystorageaccount \ --container-name mycontainer \ --name myblob \ --file /path/to/file \ --auth-mode key
Refer to the exhibit.
{
"version": "1.0",
"aggregation": {
"aggregationInterval": "00:05:00",
"aggregationType": "Average"
},
"effectiveStartTime": "2023-01-01T00:00:00Z",
"effectiveEndTime": "2023-12-31T23:59:59Z",
"metrics": [
{
"name": "MemoryPercent",
"displayName": "Memory Usage",
"unit": "Percent",
"aggregationType": "Average",
"dimensions": []
}
]
}{
"properties": {
"enabled": true,
"events": [
"Microsoft.Storage.BlobCreated",
"Microsoft.Storage.BlobDeleted"
],
"destination": {
"endpointType": "WebHook",
"properties": {
"endpointUrl": "https://myapp.azurewebsites.net/api/events"
}
},
"filter": {
"subjectBeginsWith": "/blobServices/default/containers/images/",
"subjectEndsWith": ".jpg"
}
}
}{
"type": "Microsoft.KeyVault/vaults",
"apiVersion": "2022-07-01",
"name": "myKeyVault",
"location": "[resourceGroup().location]",
"properties": {
"sku": {
"family": "A",
"name": "standard"
},
"tenantId": "[subscription().tenantId]",
"accessPolicies": [],
"enabledForDeployment": false,
"enabledForDiskEncryption": false,
"enabledForTemplateDeployment": false,
"enableSoftDelete": true,
"softDeleteRetentionInDays": 90,
"enableRbacAuthorization": true
}
}Refer to the exhibit.
```json
{
"type": "Microsoft.DataFactory/factories/pipelines",
"properties": {
"activities": [
{
"name": "CopyData",
"type": "Copy",
"inputs": [
{
"referenceName": "BlobInput",
"type": "DatasetReference"
}
],
"outputs": [
{
"referenceName": "SqlOutput",
"type": "DatasetReference"
}
],
"typeProperties": {
"source": {
"type": "BlobSource"
},
"sink": {
"type": "SqlSink"
}
}
}
]
}
}
```Refer to the exhibit.
```json
{
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"resources": [
{
"type": "Microsoft.Web/sites",
"apiVersion": "2021-03-01",
"name": "[parameters('webAppName')]",
"location": "[resourceGroup().location]",
"properties": {
"siteConfig": {
"appSettings": [
{
"name": "CosmosDbConnectionString",
"value": "[listKeys(resourceId('Microsoft.DocumentDB/databaseAccounts', parameters('cosmosAccountName')), '2021-04-15').primaryMasterKey]"
}
]
}
}
}
]
}
```Refer to the exhibit.
```json
{
"parameters": {
"eventHubConnectionString": {
"type": "securestring"
},
"storageAccountName": {
"type": "string"
}
},
"functions": [
{
"name": "EventProcessor",
"type": "EventHubTrigger",
"direction": "in",
"eventHubName": "telemetry",
"connection": "EventHubConnectionString",
"cardinality": "many",
"consumerGroup": "$Default"
}
]
}
```{
"type": "Microsoft.ApiManagement/service/apis/policies",
"apiVersion": "2021-08-01",
"properties": {
"value": "<policies>\n <inbound>\n <base />\n <rate-limit calls=\"10\" renewal-period=\"60\" />\n </inbound>\n <backend>\n <base />\n </backend>\n <outbound>\n <base />\n </outbound>\n</policies>"
}
}{
"type": "Microsoft.Storage/storageAccounts/blobServices/containers",
"apiVersion": "2021-02-01",
"name": "images-container",
"properties": {
"publicAccess": "None"
}
}{
"resources": [
{
"type": "Microsoft.Storage/storageAccounts",
"apiVersion": "2021-09-01",
"name": "[parameters('storageName')]",
"location": "[resourceGroup().location]",
"kind": "StorageV2",
"sku": {
"name": "Standard_LRS"
},
"properties": {
"minimumTlsVersion": "TLS1_2",
"supportsHttpsTrafficOnly": true
}
}
]
}{
"queues": [
{
"name": "orders",
"maxDeliveryCount": 10,
"lockDuration": "PT30S",
"defaultMessageTimeToLive": "PT5M"
}
]
}Refer to the exhibit.
{
"type": "Microsoft.ApiManagement/service/apis/operations/policies",
"apiVersion": "2021-12-01-preview",
"properties": {
"value": "<policies>\n <inbound>\n <base />\n <rate-limit calls=\"100\" renewal-period=\"60\" />\n </inbound>\n</policies>"
}
}