Skip to content

Commit

Permalink
EES-XXXX - adding capture of specific Public API errors to Grafana da…
Browse files Browse the repository at this point in the history
…shboard
  • Loading branch information
duncan-at-hiveit committed Dec 17, 2024
1 parent dee7e0c commit 0d78433
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 20 deletions.
39 changes: 23 additions & 16 deletions tests/performance-tests/dashboards/ees-dashboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -3080,7 +3080,8 @@
"mode": "absolute",
"steps": [
{
"color": "light-red"
"color": "light-red",
"value": null
},
{
"color": "red",
Expand Down Expand Up @@ -3116,13 +3117,13 @@
"type": "influxdb",
"uid": "P76A45B24F43298D1"
},
"query": "SELECT count(\"value\") FROM \"ees_public_api_query_http2_stream_error_count\" WHERE $timeFilter GROUP BY time(1m) fill(none)",
"query": "SELECT count(\"value\") FROM \"ees_public_api_query_gateway_timeout_error_count\" WHERE $timeFilter GROUP BY time(1m) fill(none)",
"rawQuery": true,
"refId": "A",
"resultFormat": "time_series"
}
],
"title": "Public API Data Set - query \"http2: stream\" errors per minute",
"title": "Public API Data Set - gateway timeout errors per minute",
"type": "timeseries"
},
{
Expand Down Expand Up @@ -3172,7 +3173,8 @@
"mode": "absolute",
"steps": [
{
"color": "light-red"
"color": "light-red",
"value": null
},
{
"color": "red",
Expand Down Expand Up @@ -3233,7 +3235,8 @@
"mode": "absolute",
"steps": [
{
"color": "light-red"
"color": "light-red",
"value": null
},
{
"color": "red",
Expand Down Expand Up @@ -3328,7 +3331,8 @@
"mode": "absolute",
"steps": [
{
"color": "light-red"
"color": "light-red",
"value": null
},
{
"color": "red",
Expand Down Expand Up @@ -3389,7 +3393,8 @@
"mode": "absolute",
"steps": [
{
"color": "light-red"
"color": "light-red",
"value": null
},
{
"color": "red",
Expand Down Expand Up @@ -3428,13 +3433,13 @@
"type": "influxdb",
"uid": "P76A45B24F43298D1"
},
"query": "SELECT sum(\"value\") FROM \"ees_public_api_query_http2_stream_error_count\" WHERE $timeFilter fill(none)",
"query": "SELECT sum(\"value\") FROM \"ees_public_api_query_gateway_timeout_error_count\" WHERE $timeFilter fill(none)",
"rawQuery": true,
"refId": "A",
"resultFormat": "time_series"
}
],
"title": "Public API Data Set - query \"http2: stream\" errors",
"title": "Public API Data Set - gateway timeout errors",
"type": "stat"
},
{
Expand All @@ -3453,7 +3458,8 @@
"mode": "absolute",
"steps": [
{
"color": "light-red"
"color": "light-red",
"value": null
},
{
"color": "red",
Expand Down Expand Up @@ -3517,7 +3523,8 @@
"mode": "absolute",
"steps": [
{
"color": "light-red"
"color": "light-red",
"value": null
},
{
"color": "red",
Expand Down Expand Up @@ -3922,7 +3929,7 @@
"type": "row"
}
],
"refresh": "5s",
"refresh": false,
"schemaVersion": 37,
"style": "dark",
"tags": [],
Expand Down Expand Up @@ -3952,13 +3959,13 @@
]
},
"time": {
"from": "now-5m",
"to": "now"
"from": "2024-12-17T16:26:32.679Z",
"to": "2024-12-17T16:26:50.464Z"
},
"timepicker": {},
"timezone": "",
"title": "EES dashboard",
"uid": "ees-dashboard",
"version": 1,
"version": 2,
"weekStart": ""
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@ export const connectionRefusedErrorRate = new Rate(
export const connectionResetErrorRate = new Rate(
'ees_public_api_query_connection_reset_count',
);
export const http2StreamErrorRate = new Rate(
'ees_public_api_query_http2_stream_error_count',
export const gatewayTimeoutErrorRate = new Rate(
'ees_public_api_query_gateway_timeout_error_count',
);

export interface PublicationAndDataSets extends Publication {
Expand Down Expand Up @@ -208,8 +208,8 @@ const performTest = ({ publications }: SetupData) => {
connectionResetErrorRate.add(1);
}

if (error.error_code >= 1630 && error.error_code <= 1649) {
http2StreamErrorRate.add(1);
if (error.error_code === 1504) {
gatewayTimeoutErrorRate.add(1);
}

if (error.status === 400 || error.status === 500) {
Expand Down

0 comments on commit 0d78433

Please sign in to comment.