Monitorar o uso da cota de rastros e os intervalos processados
Mantenha tudo organizado com as coleções
Salve e categorize o conteúdo com base nas suas preferências.
Você pode criar políticas de alertas no Cloud Monitoring para monitorar o número de períodos do Cloud Trace ingeridos por mês, o uso da cota e a taxa de ingestão de períodos. Se você nunca criou
uma política de alertas, consulte Como gerenciar políticas de alertas para
informações detalhadas sobre como usar o console do Cloud Monitoring.
Monitorar o uso excessivo da API Cloud Trace
Para criar uma política de alertas que é acionada quando os períodos mensais ingeridos do Cloud Trace ultrapassam sua cota, use as seguintes configurações:
Se você usar a barra de pesquisa para encontrar essa página, selecione o resultado com o subtítulo Monitoring.
Se você não tiver criado seus canais de notificação e quiser receber uma notificação, clique em
Editar canais de notificação e adicione-os. Volte para a página
Alertas depois de adicionar seus canais.
Na página Alertas, clique em Criar política.
Para selecionar o recurso, a métrica e os filtros, expanda o menu Selecionar uma métrica e
use os valores na tabela Nova condição:
(Opcional) Para limitar o menu a entradas relevantes, insira o nome do recurso ou
da métrica na barra de filtro.
Selecione um Tipo de recurso. Por exemplo, selecione Instância de VM.
Selecione uma Categoria de métrica. Por exemplo, selecione instância.
Selecione uma Métrica. Por exemplo, selecione CPU Utilization.
Selecione Apply.
Clique em Avançar e configure o acionador da política de alertas.
Para preencher esses campos, use os valores na tabela Configurar gatilho de alerta.
Clique em Próxima.
Opcional: para adicionar notificações à sua política de alertas, clique em
Canais de notificação. Na caixa de diálogo, selecione um ou mais canais de notificação no menu e clique em OK.
(Opcional) Para receber uma notificação quando os incidentes forem abertos ou fechados, marque
Notificar sobre o fechamento de incidentes. Por padrão, as notificações são enviadas apenas quando
incidentes são abertos.
Opcional: Atualize a Duração do fechamento automático do incidente. Este campo determina quando o
Monitoring fecha incidentes na ausência de dados de métrica.
Opcional: clique em Documentação e adicione
as informações que quer incluir em uma mensagem de notificação.
Clique em Nome e digite um nome para a política de alertas.
Clique em Criar política.
Novo estado Campo
Valor
Recurso e métrica
No menu Recursos, selecione API consumida.
No menu Categorias de métrica, selecione API.
No menu Métricas, selecione Contagem de solicitações.
O metric.type é serviceruntime.googleapis.com/api/request_count.
Filtrar
service = cloudtrace.googleapis.com response_code = 429
Várias séries
Agregação de série temporal
sum
Janela contínua
1 m
Função de janela contínua
sum
Campo Configurar gatilho de alerta
Valor
Tipo de condição
Threshold
Acionador de alerta
Any time series violates
Posição do limite
Above threshold
Valor do limite
0
Teste a janela novamente
1 minute
Monitorar a ingestão de períodos mensais
Para criar uma política de alertas acionada quando os períodos mensais do Cloud Trace ingeridos ultrapassarem um limite definido pelo usuário, use as seguintes configurações.
Se você usar a barra de pesquisa para encontrar essa página, selecione o resultado com o subtítulo Monitoring.
Se você não tiver criado seus canais de notificação e quiser receber uma notificação, clique em
Editar canais de notificação e adicione-os. Volte para a página
Alertas depois de adicionar seus canais.
Na página Alertas, clique em Criar política.
Para selecionar o recurso, a métrica e os filtros, expanda o menu Selecionar uma métrica e
use os valores na tabela Nova condição:
(Opcional) Para limitar o menu a entradas relevantes, insira o nome do recurso ou
da métrica na barra de filtro.
Selecione um Tipo de recurso. Por exemplo, selecione Instância de VM.
Selecione uma Categoria de métrica. Por exemplo, selecione instância.
Selecione uma Métrica. Por exemplo, selecione CPU Utilization.
Selecione Apply.
Clique em Avançar e configure o acionador da política de alertas.
Para preencher esses campos, use os valores na tabela Configurar gatilho de alerta.
Clique em Próxima.
Opcional: para adicionar notificações à sua política de alertas, clique em
Canais de notificação. Na caixa de diálogo, selecione um ou mais canais de notificação no menu e clique em OK.
(Opcional) Para receber uma notificação quando os incidentes forem abertos ou fechados, marque
Notificar sobre o fechamento de incidentes. Por padrão, as notificações são enviadas apenas quando
incidentes são abertos.
Opcional: Atualize a Duração do fechamento automático do incidente. Este campo determina quando o
Monitoring fecha incidentes na ausência de dados de métrica.
Opcional: clique em Documentação e adicione
as informações que quer incluir em uma mensagem de notificação.
Clique em Nome e digite um nome para a política de alertas.
Clique em Criar política.
Novo estado Campo
Valor
Recurso e métrica
No menu Recursos, selecione Global.
No menu Categorias de métrica, selecione Faturamento.
No menu Métricas, selecione Intervalos de rastros mensais processados.
Filtrar
Várias séries
Agregação de série temporal
sum
Janela contínua
60 m
Função de janela contínua
max
Campo Configurar gatilho de alerta
Valor
Tipo de condição
Threshold
Acionador de alerta
Any time series violates
Posição do limite
Above threshold
Threshold value
Você determina o valor aceitável.
Teste a janela novamente
O valor mínimo aceitável é de 30 minutos.
Monitorar a taxa de ingestão de intervalo
Também é possível monitorar a taxa de ingestão de spans. Nesse caso,
selecione o tipo de métrica Trace spans ingested. As configurações padrão
nas seções Transformar dados e Em séries temporais são
adequadas para esse tipo de métrica.
[[["Fácil de entender","easyToUnderstand","thumb-up"],["Meu problema foi resolvido","solvedMyProblem","thumb-up"],["Outro","otherUp","thumb-up"]],[["Difícil de entender","hardToUnderstand","thumb-down"],["Informações incorretas ou exemplo de código","incorrectInformationOrSampleCode","thumb-down"],["Não contém as informações/amostras de que eu preciso","missingTheInformationSamplesINeed","thumb-down"],["Problema na tradução","translationIssue","thumb-down"],["Outro","otherDown","thumb-down"]],["Última atualização 2025-08-19 UTC."],[],[],null,["# Monitor trace quota usage and spans ingested\n\nYou can create alerting policies in Cloud Monitoring\nto monitor the number of Cloud Trace spans ingested per month,\nyour quota usage, and your rate of span ingestion. If you have never created\nan alerting policy, see [Managing alerting policies](/monitoring/alerts/using-alerting-ui) for\ndetailed information about using the Cloud Monitoring console.\n\nMonitor over-quota on Cloud Trace API usage\n-------------------------------------------\n\nTo create an alerting policy that triggers when your monthly\n[Cloud Trace](/trace/docs) spans ingested\nexceeds your quota, use the following settings.\n\n#### Steps to create an [alerting policy](/monitoring/alerts/using-alerting-ui#create-policy).\n\nTo create an alerting policy, do the following:\n\n1. In the Google Cloud console, go to the\n *notifications* **Alerting** page:\n\n [Go to **Alerting**](https://console.cloud.google.com/monitoring/alerting)\n\n \u003cbr /\u003e\n\n If you use the search bar to find this page, then select the result whose subheading is\n **Monitoring**.\n2. If you haven't created your notification channels and if you want to be notified, then click **Edit Notification Channels** and add your notification channels. Return to the **Alerting** page after you add your channels.\n3. From the **Alerting** page, select **Create policy**.\n4. To select the resource, metric, and filters, expand the **Select a metric** menu and then use the values in the **New condition** table:\n 1. Optional: To limit the menu to relevant entries, enter the resource or metric name in the filter bar.\n 2. Select a **Resource type** . For example, select **VM instance**.\n 3. Select a **Metric category** . For example, select **instance**.\n 4. Select a **Metric** . For example, select **CPU Utilization**.\n 5. Select **Apply**.\n5. Click **Next** and then configure the alerting policy trigger. To complete these fields, use the values in the **Configure alert trigger** table.\n6. Click **Next**.\n7. Optional: To add notifications to your alerting policy, click\n **Notification channels** . In the dialog, select one or more notification\n channels from the menu, and then click **OK**.\n\n To be notified when incidents are openend and closed, check\n **Notify on incident closure**. By default, notifications are sent only when\n incidents are openend.\n8. Optional: Update the **Incident autoclose duration**. This field determines when Monitoring closes incidents in the absence of metric data.\n9. Optional: Click **Documentation**, and then add any information that you want included in a notification message.\n10. Click **Alert name** and enter a name for the alerting policy.\n11. Click **Create Policy**.\n\nMonitor monthly span ingestion\n------------------------------\n\nTo create an alerting policy that triggers when your monthly\n[Cloud Trace](/trace/docs) spans ingested\nexceeds a user-defined limit, use the following settings.\n\n#### Steps to create an [alerting policy](/monitoring/alerts/using-alerting-ui#create-policy).\n\nTo create an alerting policy, do the following:\n\n1. In the Google Cloud console, go to the\n *notifications* **Alerting** page:\n\n [Go to **Alerting**](https://console.cloud.google.com/monitoring/alerting)\n\n \u003cbr /\u003e\n\n If you use the search bar to find this page, then select the result whose subheading is\n **Monitoring**.\n2. If you haven't created your notification channels and if you want to be notified, then click **Edit Notification Channels** and add your notification channels. Return to the **Alerting** page after you add your channels.\n3. From the **Alerting** page, select **Create policy**.\n4. To select the resource, metric, and filters, expand the **Select a metric** menu and then use the values in the **New condition** table:\n 1. Optional: To limit the menu to relevant entries, enter the resource or metric name in the filter bar.\n 2. Select a **Resource type** . For example, select **VM instance**.\n 3. Select a **Metric category** . For example, select **instance**.\n 4. Select a **Metric** . For example, select **CPU Utilization**.\n 5. Select **Apply**.\n5. Click **Next** and then configure the alerting policy trigger. To complete these fields, use the values in the **Configure alert trigger** table.\n6. Click **Next**.\n7. Optional: To add notifications to your alerting policy, click\n **Notification channels** . In the dialog, select one or more notification\n channels from the menu, and then click **OK**.\n\n To be notified when incidents are openend and closed, check\n **Notify on incident closure**. By default, notifications are sent only when\n incidents are openend.\n8. Optional: Update the **Incident autoclose duration**. This field determines when Monitoring closes incidents in the absence of metric data.\n9. Optional: Click **Documentation**, and then add any information that you want included in a notification message.\n10. Click **Alert name** and enter a name for the alerting policy.\n11. Click **Create Policy**.\n\nMonitor rate of span ingestion\n------------------------------\n\nYou can also monitor the rate at which spans are ingested. For this case,\nyou want to select the metric type **Trace spans ingested** . The default\nsettings in the **Transform data** and **Across time series** sections are\nappropriate for this metric type."]]