Skip to content

Commit

Permalink
fix incorrect examples (#26844)
Browse files Browse the repository at this point in the history
  • Loading branch information
VeryEarly authored Dec 6, 2024
1 parent 73da24c commit 0822e30
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ Adds a list of callout policies for engine services.

## EXAMPLES

### Example 1:
### Example 1: Adding two callout policies to a cluster
```powershell
$kustoCalloutPolicy = [Microsoft.Azure.PowerShell.Cmdlets.Kusto.Models.Api20240413.ICalloutPolicy]@{
calloutType = "kusto"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ Returns the allowed callout policies for the specified service.

## EXAMPLES

### Example 1:
### Example 1: List callout policies to a cluster
```powershell
Get-AzKustoClusterCalloutPolicy -ResourceGroupName rg1 -ClusterName cluster1 -SubscriptionId sub
Expand Down
Original file line number Diff line number Diff line change
@@ -1,16 +1,19 @@
### Example 1: Adding two callout policies to a cluster
### Example 1: List callout policies to a cluster
```powershell
$kustoCalloutPolicy = [Microsoft.Azure.PowerShell.Cmdlets.Kusto.Models.Api20240413.ICalloutPolicy]@{
calloutType = "kusto"
outboundAccess = "Allow"
calloutUriRegex = "*"
}
$sqlCalloutPolicy = [Microsoft.Azure.PowerShell.Cmdlets.Kusto.Models.Api20240413.ICalloutPolicy]@{
calloutType = "sql"
outboundAccess = "Deny"
calloutUriRegex = "*"
}
Add-AzKustoClusterCalloutPolicy -ResourceGroupName rg1 -ClusterName cluster1 -SubscriptionId sub -Value -Value @($kustoCalloutPolicy, $sqlCalloutPolicy)
Get-AzKustoClusterCalloutPolicy -ResourceGroupName rg1 -ClusterName cluster1 -SubscriptionId sub
```

```output
CalloutId CalloutType CalloutUriRegex OutboundAccess
--------- ----------- --------------- --------------
*_cosmosdb cosmosdb * Allow
*_postgresql postgresql * Deny
*_sandbox_artifacts sandbox_artifacts * Allow
*_genevametrics genevametrics * Deny
*_kusto kusto * Allow
*_sql sql * Deny
```

The above command adds the two defined callout policies to cluster1 in rg1.
The above command returns a list of the callout policies of cluster1 in rg1.

0 comments on commit 0822e30

Please sign in to comment.