源文件
gcp/monitoring/policies/error-log-spike.json
离线配置。未部署到任何云账号。
{
"displayName": "insights-api application error log spike",
"combiner": "OR",
"severity": "ERROR",
"enabled": true,
"summary": "Log-based metric insights_api_app_errors increased above 20 lines in 5 minutes.",
"documentation": {
"content": "The log-based metric insights_api_app_errors counts Cloud Run lines at severity ERROR or higher for service insights-api. Healthz probe noise is excluded by the logging exclusion insights-api-healthz-noise. This policy is not deployed.",
"mimeType": "text/markdown"
},
"conditions": [
{
"displayName": "error log lines above 20",
"conditionThreshold": {
"filter": "resource.type=\"cloud_run_revision\" AND metric.type=\"logging.googleapis.com/user/insights_api_app_errors\"",
"comparison": "COMPARISON_GT",
"thresholdValue": 20,
"duration": "300s",
"aggregations": [
{
"alignmentPeriod": "60s",
"perSeriesAligner": "ALIGN_DELTA",
"crossSeriesReducer": "REDUCE_SUM"
}
]
}
}
],
"notificationChannels": [
"projects/thistle-analytics-demo/notificationChannels/placeholder-channel"
]
}