az spring-cloud app-insights

Note

This reference is part of the spring-cloud extension for the Azure CLI (version 2.30.0 or higher). The extension will automatically install the first time you run an az spring-cloud app-insights command. Learn more about extensions.

Commands to management Application Insights in Azure Spring Cloud.

Commands

az spring-cloud app-insights show

Show Application Insights settings.

az spring-cloud app-insights update

Update Application Insights settings.

az spring-cloud app-insights show

Show Application Insights settings.

az spring-cloud app-insights show --name
                                  --resource-group

Required Parameters

--name -n

Name of Azure Spring Cloud.

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

az spring-cloud app-insights update

Update Application Insights settings.

az spring-cloud app-insights update --name
                                    --resource-group
                                    [--app-insights]
                                    [--app-insights-key]
                                    [--disable {false, true}]
                                    [--no-wait]
                                    [--sampling-rate]

Examples

Enable Application Insights by using the Connection string (recommended) or Instrumentation key.

az spring-cloud app-insights update -n MyService -g MyResourceGroup --app-insights-key "MyConnectionString" --sampling-rate 100

Disable Application Insights.

az spring-cloud app-insights update -n MyService -g MyResourceGroup --disable

Required Parameters

--name -n

Name of Azure Spring Cloud.

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

Optional Parameters

--app-insights

Name of the existing Application Insights in the same Resource Group. Or Resource ID of the existing Application Insights in a different Resource Group.

--app-insights-key

Connection string (recommended) or Instrumentation key of the existing Application Insights.

--disable

Disable Application Insights.

accepted values: false, true
--no-wait

Do not wait for the long-running operation to finish.

--sampling-rate

Sampling Rate of application insights. Maximum is 100.