Share via


Microsoft.AppPlatform Spring/monitoringSettings 2020-07-01

Remarks

Note: Azure Spring Apps Monitoring Settings (Microsoft.AppPlatform/Spring/monitoringSettings) is now deprecated and will be retired on 2028-05-31. See https://aka.ms/asaretirement for more information.

Bicep resource definition

The Spring/monitoringSettings resource type can be deployed with operations that target:

For a list of changed properties in each API version, see change log.

Resource format

To create a Microsoft.AppPlatform/Spring/monitoringSettings resource, add the following Bicep to your template.

resource symbolicname 'Microsoft.AppPlatform/Spring/monitoringSettings@2020-07-01' = {
  parent: resourceSymbolicName
  name: 'default'
  properties: {
    appInsightsInstrumentationKey: 'string'
    error: {
      code: 'string'
      message: 'string'
    }
    traceEnabled: bool
  }
}

Property Values

Microsoft.AppPlatform/Spring/monitoringSettings

Name Description Value
name The resource name 'default' (required)
parent In Bicep, you can specify the parent resource for a child resource. You only need to add this property when the child resource is declared outside of the parent resource.

For more information, see Child resource outside parent resource.
Symbolic name for resource of type: Spring
properties Properties of the Monitoring Setting resource MonitoringSettingProperties

Error

Name Description Value
code The code of error. string
message The message of error. string

MonitoringSettingProperties

Name Description Value
appInsightsInstrumentationKey Target application insight instrumentation key string
error Error when apply Monitoring Setting changes. Error
traceEnabled Indicates whether enable the trace functionality bool

Usage Examples

Azure Quickstart Samples

The following Azure Quickstart templates contain Bicep samples for deploying this resource type.

Bicep File Description
Deploy a simple Azure Spring Apps microservice application This template deploys a simple Azure Spring Apps microservice application to run on Azure.

ARM template resource definition

The Spring/monitoringSettings resource type can be deployed with operations that target:

For a list of changed properties in each API version, see change log.

Resource format

To create a Microsoft.AppPlatform/Spring/monitoringSettings resource, add the following JSON to your template.

{
  "type": "Microsoft.AppPlatform/Spring/monitoringSettings",
  "apiVersion": "2020-07-01",
  "name": "string",
  "properties": {
    "appInsightsInstrumentationKey": "string",
    "error": {
      "code": "string",
      "message": "string"
    },
    "traceEnabled": "bool"
  }
}

Property Values

Microsoft.AppPlatform/Spring/monitoringSettings

Name Description Value
apiVersion The api version '2020-07-01'
name The resource name 'default' (required)
properties Properties of the Monitoring Setting resource MonitoringSettingProperties
type The resource type 'Microsoft.AppPlatform/Spring/monitoringSettings'

Error

Name Description Value
code The code of error. string
message The message of error. string

MonitoringSettingProperties

Name Description Value
appInsightsInstrumentationKey Target application insight instrumentation key string
error Error when apply Monitoring Setting changes. Error
traceEnabled Indicates whether enable the trace functionality bool

Usage Examples

Azure Quickstart Templates

The following Azure Quickstart templates deploy this resource type.

Template Description
Deploy a simple Azure Spring Apps microservice application

Deploy to Azure
This template deploys a simple Azure Spring Apps microservice application to run on Azure.

Terraform (AzAPI provider) resource definition

The Spring/monitoringSettings resource type can be deployed with operations that target:

For a list of changed properties in each API version, see change log.

Resource format

To create a Microsoft.AppPlatform/Spring/monitoringSettings resource, add the following Terraform to your template.

resource "azapi_resource" "symbolicname" {
  type = "Microsoft.AppPlatform/Spring/monitoringSettings@2020-07-01"
  name = "string"
  parent_id = "string"
  body = {
    properties = {
      appInsightsInstrumentationKey = "string"
      error = {
        code = "string"
        message = "string"
      }
      traceEnabled = bool
    }
  }
}

Property Values

Microsoft.AppPlatform/Spring/monitoringSettings

Name Description Value
name The resource name 'default' (required)
parent_id The ID of the resource that is the parent for this resource. ID for resource of type: Spring
properties Properties of the Monitoring Setting resource MonitoringSettingProperties
type The resource type "Microsoft.AppPlatform/Spring/monitoringSettings@2020-07-01"

Error

Name Description Value
code The code of error. string
message The message of error. string

MonitoringSettingProperties

Name Description Value
appInsightsInstrumentationKey Target application insight instrumentation key string
error Error when apply Monitoring Setting changes. Error
traceEnabled Indicates whether enable the trace functionality bool

Usage Examples

Terraform Samples

A basic example of deploying Spring Cloud Monitoring Settings.

terraform {
  required_providers {
    azapi = {
      source = "Azure/azapi"
    }
  }
}

provider "azapi" {
  skip_provider_registration = false
}

variable "resource_name" {
  type    = string
  default = "acctest0001"
}

variable "location" {
  type    = string
  default = "westeurope"
}

resource "azapi_resource" "resourceGroup" {
  type     = "Microsoft.Resources/resourceGroups@2020-06-01"
  name     = var.resource_name
  location = var.location
}

resource "azapi_resource" "Spring" {
  type      = "Microsoft.AppPlatform/Spring@2023-05-01-preview"
  parent_id = azapi_resource.resourceGroup.id
  name      = var.resource_name
  location  = var.location
  body = {
    properties = {
      zoneRedundant = false
    }
    sku = {
      name = "S0"
    }
  }
  schema_validation_enabled = false
  response_export_values    = ["*"]
}

resource "azapi_update_resource" "monitoringSetting" {
  type      = "Microsoft.AppPlatform/Spring/monitoringSettings@2023-05-01-preview"
  parent_id = azapi_resource.Spring.id
  name      = "default"
  body = {
    properties = {
      traceEnabled = false
    }
  }
  response_export_values = ["*"]
}