Partilhar via


ApplicationInsightsComponentCollection.CreateOrUpdate Método

Definição

Cria (ou atualiza) um componente do Application Insights. Observação: você não pode especificar um valor diferente para InstrumentationKey nem AppId na operação Put.

  • Caminho da Solicitação/assinaturas/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Insights/components/{resourceName}
  • IdComponents_CreateOrUpdate de operação
public virtual Azure.ResourceManager.ArmOperation<Azure.ResourceManager.ApplicationInsights.ApplicationInsightsComponentResource> CreateOrUpdate (Azure.WaitUntil waitUntil, string resourceName, Azure.ResourceManager.ApplicationInsights.ApplicationInsightsComponentData data, System.Threading.CancellationToken cancellationToken = default);
abstract member CreateOrUpdate : Azure.WaitUntil * string * Azure.ResourceManager.ApplicationInsights.ApplicationInsightsComponentData * System.Threading.CancellationToken -> Azure.ResourceManager.ArmOperation<Azure.ResourceManager.ApplicationInsights.ApplicationInsightsComponentResource>
override this.CreateOrUpdate : Azure.WaitUntil * string * Azure.ResourceManager.ApplicationInsights.ApplicationInsightsComponentData * System.Threading.CancellationToken -> Azure.ResourceManager.ArmOperation<Azure.ResourceManager.ApplicationInsights.ApplicationInsightsComponentResource>
Public Overridable Function CreateOrUpdate (waitUntil As WaitUntil, resourceName As String, data As ApplicationInsightsComponentData, Optional cancellationToken As CancellationToken = Nothing) As ArmOperation(Of ApplicationInsightsComponentResource)

Parâmetros

waitUntil
WaitUntil

Completed se o método deve aguardar para retornar até que a operação de execução prolongada seja concluída no serviço; Started se ele deve retornar depois de iniciar a operação. Para obter mais informações sobre operações de longa execução, consulte Exemplos de operação de Long-Running do Azure.Core.

resourceName
String

O nome do recurso de componente do Application Insights.

data
ApplicationInsightsComponentData

Propriedades que precisam ser especificadas para criar um componente do Application Insights.

cancellationToken
CancellationToken

O token de cancelamento a ser usado.

Retornos

Exceções

resourceName é uma cadeia de caracteres vazia e era esperado que não estivesse vazio.

resourceName ou data é nulo.

Aplica-se a