Skip to content

Instantly share code, notes, and snippets.

@alepane21
Last active October 16, 2025 08:47
Show Gist options
  • Select an option

  • Save alepane21/56be5c17f5fe81237992d2ce4bb8ec2a to your computer and use it in GitHub Desktop.

Select an option

Save alepane21/56be5c17f5fe81237992d2ce4bb8ec2a to your computer and use it in GitHub Desktop.
Cosmo Dashboard for New Relic
{
"name": "Cosmo Router",
"description": null,
"permissions": "PUBLIC_READ_WRITE",
"pages": [
{
"name": "Cosmo Router",
"description": null,
"widgets": [
{
"id": "493405730",
"title": "Request Rate",
"layout": {
"column": 1,
"row": 1,
"width": 4,
"height": 3
},
"linkedEntityGuids": [],
"visualization": {
"id": "viz.line"
},
"rawConfiguration": {
"facet": {
"showOtherSeries": false
},
"legend": {
"enabled": true
},
"markers": {
"displayedTypes": {
"criticalViolations": false,
"deployments": true,
"relatedDeployments": true,
"warningViolations": false
}
},
"nrqlQueries": [
{
"accountIds": [
7224461
],
"query": "SELECT rate(count(*), 1 minute) AS 'RPM' FROM Span WHERE category = 'http' and span.kind = 'server' AND entity.name = 'cosmo-router' TIMESERIES 1 minutes"
}
],
"nullValues": {
"nullValue": "zero"
},
"platformOptions": {
"ignoreTimeRange": false
},
"thresholds": {
"isLabelVisible": true
},
"yAxisLeft": {
"zero": true
},
"yAxisRight": {
"zero": true
}
}
},
{
"id": "493405731",
"title": "P95 Latency",
"layout": {
"column": 5,
"row": 1,
"width": 4,
"height": 3
},
"linkedEntityGuids": [],
"visualization": {
"id": "viz.line"
},
"rawConfiguration": {
"facet": {
"showOtherSeries": false
},
"legend": {
"enabled": true
},
"markers": {
"displayedTypes": {
"criticalViolations": false,
"deployments": true,
"relatedDeployments": true,
"warningViolations": false
}
},
"nrqlQueries": [
{
"accountIds": [
7224461
],
"query": "SELECT percentile(duration.ms, 95) as 'Response time' FROM Span WHERE category = 'http' and span.kind = 'server' AND entity.name = 'cosmo-router' TIMESERIES 1 minutes"
}
],
"platformOptions": {
"ignoreTimeRange": false
},
"thresholds": {
"isLabelVisible": true
},
"yAxisLeft": {
"zero": true
},
"yAxisRight": {
"zero": true
}
}
},
{
"id": "493405732",
"title": "Errors",
"layout": {
"column": 9,
"row": 1,
"width": 4,
"height": 3
},
"linkedEntityGuids": [],
"visualization": {
"id": "viz.line"
},
"rawConfiguration": {
"facet": {
"showOtherSeries": false
},
"legend": {
"enabled": true
},
"markers": {
"displayedTypes": {
"criticalViolations": false,
"deployments": true,
"relatedDeployments": true,
"warningViolations": false
}
},
"nrqlQueries": [
{
"accountIds": [
7224461
],
"query": "SELECT percentage(count(*), WHERE (http.status_code >= 400 AND http.status_code < 600) or error = true) AS errors FROM Span WHERE category = 'http' and span.kind = 'server' AND entity.name = 'cosmo-router' TIMESERIES 1 minutes"
}
],
"nullValues": {
"nullValue": "zero"
},
"platformOptions": {
"ignoreTimeRange": false
},
"thresholds": {
"isLabelVisible": true
},
"yAxisLeft": {
"zero": true
},
"yAxisRight": {
"zero": true
}
}
},
{
"id": "493405733",
"title": "Error rate over time",
"layout": {
"column": 1,
"row": 4,
"width": 12,
"height": 3
},
"linkedEntityGuids": [],
"visualization": {
"id": "viz.line"
},
"rawConfiguration": {
"colors": {
"seriesOverrides": [
{
"color": "#ff0000",
"seriesName": "errors"
},
{
"color": "#c9c9c9",
"seriesName": "ok"
}
]
},
"facet": {
"showOtherSeries": false
},
"legend": {
"enabled": true
},
"markers": {
"displayedTypes": {
"criticalViolations": false,
"deployments": true,
"relatedDeployments": true,
"warningViolations": false
}
},
"nrqlQueries": [
{
"accountIds": [
7224461
],
"query": "SELECT filter(rate(count(*), 1 minute), WHERE (http.status_code >= 400 AND http.status_code < 600) or error = true) AS errors, filter(count(*), WHERE (http.status_code >= 400 AND http.status_code < 600) or (error = false or error is null)) AS ok FROM Span WHERE category = 'http' and span.kind = 'server' AND entity.name = 'cosmo-router' TIMESERIES 1 minutes"
}
],
"nullValues": {
"nullValue": "zero"
},
"platformOptions": {
"ignoreTimeRange": false
},
"thresholds": {
"isLabelVisible": true
},
"yAxisLeft": {
"zero": true
},
"yAxisRight": {
"zero": true
}
}
},
{
"id": "493405734",
"title": "Latency",
"layout": {
"column": 1,
"row": 7,
"width": 12,
"height": 3
},
"linkedEntityGuids": [],
"visualization": {
"id": "viz.line"
},
"rawConfiguration": {
"facet": {
"showOtherSeries": false
},
"legend": {
"enabled": true
},
"markers": {
"displayedTypes": {
"criticalViolations": false,
"deployments": true,
"relatedDeployments": true,
"warningViolations": false
}
},
"nrqlQueries": [
{
"accountIds": [
7224461
],
"query": "SELECT percentile(duration.ms, 99) as 'P99', percentile(duration.ms, 90) as 'P90', percentile(duration.ms, 50) as 'P50' FROM Span WHERE category = 'http' and span.kind = 'server' AND entity.name = 'cosmo-router' TIMESERIES 1 minutes"
}
],
"platformOptions": {
"ignoreTimeRange": false
},
"thresholds": {
"isLabelVisible": true
},
"yAxisLeft": {
"zero": true
},
"yAxisRight": {
"zero": true
}
}
}
]
}
],
"variables": []
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment