Skip to content

Commit

Permalink
chore: add onguard and trustedcontent to the dashboard
Browse files Browse the repository at this point in the history
Signed-off-by: Ruben Romero Montes <rromerom@redhat.com>
  • Loading branch information
ruromero committed Mar 14, 2024
1 parent bb2e69a commit 7cc74ca
Show file tree
Hide file tree
Showing 2 changed files with 251 additions and 13 deletions.
261 changes: 249 additions & 12 deletions dashboards/grafana-dashboard-exhort.configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ data:
"editable": true,
"fiscalYearStartMonth": 0,
"graphTooltip": 0,
"id": 348444,
"links": [
{
"asDropdown": false,
Expand Down Expand Up @@ -800,6 +799,248 @@ data:
"title": "Snyk latency",
"type": "timeseries"
},
{
"datasource": {
"type": "prometheus",
"uid": "${datasource}"
},
"description": "",
"fieldConfig": {
"defaults": {
"color": {
"mode": "palette-classic"
},
"custom": {
"axisCenteredZero": false,
"axisColorMode": "text",
"axisLabel": "",
"axisPlacement": "auto",
"barAlignment": 0,
"drawStyle": "line",
"fillOpacity": 42,
"gradientMode": "none",
"hideFrom": {
"legend": false,
"tooltip": false,
"viz": false
},
"lineInterpolation": "smooth",
"lineStyle": {
"fill": "solid"
},
"lineWidth": 2,
"pointSize": 5,
"scaleDistribution": {
"type": "linear"
},
"showPoints": "never",
"spanNulls": false,
"stacking": {
"group": "A",
"mode": "none"
},
"thresholdsStyle": {
"mode": "off"
}
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "green",
"value": null
},
{
"color": "red",
"value": 80
}
]
},
"unit": "ms"
},
"overrides": []
},
"gridPos": {
"h": 8,
"w": 8,
"x": 8,
"y": 17
},
"id": 53,
"options": {
"legend": {
"calcs": [],
"displayMode": "list",
"placement": "bottom",
"showLegend": true
},
"tooltip": {
"mode": "single",
"sort": "none"
}
},
"targets": [
{
"datasource": {
"type": "prometheus",
"uid": "${datasource}"
},
"editorMode": "code",
"expr": "histogram_quantile(0.90, sum by (le) (rate(camel_route_policy_seconds_bucket{routeId=\"getTrustedContent\"}[2m])))",
"legendFormat": "0.90",
"range": true,
"refId": "A"
},
{
"datasource": {
"type": "prometheus",
"uid": "${datasource}"
},
"editorMode": "code",
"expr": "histogram_quantile(0.95, sum by (le) (rate(camel_route_policy_seconds_bucket{routeId=\"getTrustedContent\"}[2m])))",
"hide": false,
"legendFormat": "0.95",
"range": true,
"refId": "B"
},
{
"datasource": {
"type": "prometheus",
"uid": "${datasource}"
},
"editorMode": "code",
"expr": "histogram_quantile(0.99, sum by (le) (rate(camel_route_policy_seconds_bucket{routeId=\"getTrustedContent\"}[2m])))",
"hide": false,
"legendFormat": "0.99",
"range": true,
"refId": "C"
}
],
"title": "Trusted Content latency",
"type": "timeseries"
},
{
"datasource": {
"type": "prometheus",
"uid": "${datasource}"
},
"description": "",
"fieldConfig": {
"defaults": {
"color": {
"mode": "palette-classic"
},
"custom": {
"axisCenteredZero": false,
"axisColorMode": "text",
"axisLabel": "",
"axisPlacement": "auto",
"barAlignment": 0,
"drawStyle": "line",
"fillOpacity": 42,
"gradientMode": "none",
"hideFrom": {
"legend": false,
"tooltip": false,
"viz": false
},
"lineInterpolation": "smooth",
"lineStyle": {
"fill": "solid"
},
"lineWidth": 2,
"pointSize": 5,
"scaleDistribution": {
"type": "linear"
},
"showPoints": "never",
"spanNulls": false,
"stacking": {
"group": "A",
"mode": "none"
},
"thresholdsStyle": {
"mode": "off"
}
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "green",
"value": null
},
{
"color": "red",
"value": 80
}
]
},
"unit": "ms"
},
"overrides": []
},
"gridPos": {
"h": 8,
"w": 8,
"x": 16,
"y": 17
},
"id": 54,
"options": {
"legend": {
"calcs": [],
"displayMode": "list",
"placement": "bottom",
"showLegend": true
},
"tooltip": {
"mode": "single",
"sort": "none"
}
},
"targets": [
{
"datasource": {
"type": "prometheus",
"uid": "${datasource}"
},
"editorMode": "code",
"expr": "histogram_quantile(0.90, sum by (le) (rate(camel_route_policy_seconds_bucket{routeId=\"osvNvdRequest\"}[2m])))",
"legendFormat": "0.90",
"range": true,
"refId": "A"
},
{
"datasource": {
"type": "prometheus",
"uid": "${datasource}"
},
"editorMode": "code",
"expr": "histogram_quantile(0.95, sum by (le) (rate(camel_route_policy_seconds_bucket{routeId=\"osvNvdRequest\"}[2m])))",
"hide": false,
"legendFormat": "0.95",
"range": true,
"refId": "B"
},
{
"datasource": {
"type": "prometheus",
"uid": "${datasource}"
},
"editorMode": "code",
"expr": "histogram_quantile(0.99, sum by (le) (rate(camel_route_policy_seconds_bucket{routeId=\"osvNvdRequest\"}[2m])))",
"hide": false,
"legendFormat": "0.99",
"range": true,
"refId": "C"
}
],
"title": "ONGuard latency",
"type": "timeseries"
},
{
"collapsed": true,
"gridPos": {
Expand Down Expand Up @@ -859,8 +1100,7 @@ data:
"mode": "absolute",
"steps": [
{
"color": "green",
"value": null
"color": "green"
},
{
"color": "red",
Expand Down Expand Up @@ -969,8 +1209,7 @@ data:
"mode": "absolute",
"steps": [
{
"color": "green",
"value": null
"color": "green"
},
{
"color": "dark-red",
Expand Down Expand Up @@ -1095,8 +1334,7 @@ data:
"mode": "absolute",
"steps": [
{
"color": "green",
"value": null
"color": "green"
}
]
},
Expand Down Expand Up @@ -1188,8 +1426,7 @@ data:
"mode": "absolute",
"steps": [
{
"color": "green",
"value": null
"color": "green"
}
]
},
Expand Down Expand Up @@ -1481,7 +1718,7 @@ data:
"list": [
{
"current": {
"selected": true,
"selected": false,
"text": "appsrep08ue2-prometheus",
"value": "appsrep08ue2-prometheus"
},
Expand Down Expand Up @@ -1550,7 +1787,7 @@ data:
]
},
"time": {
"from": "now-1h",
"from": "now-24h",
"to": "now"
},
"timepicker": {
Expand Down Expand Up @@ -1581,7 +1818,7 @@ data:
"timezone": "utc",
"title": "Exhort",
"uid": "trusted-content-exhort",
"version": 7,
"version": 1,
"weekStart": ""
}
kind: ConfigMap
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,8 @@ protected void doCall(HealthCheckResultBuilder builder, Map<String, Object> opti

// if (httpResponseBodiesAndStatuses.stream()
// .filter(providerStatus -> Objects.nonNull(providerStatus.getCode()))
// .anyMatch(providerDetails -> providerDetails.getCode() < 400 && providerDetails.getOk())) {
// .anyMatch(providerDetails -> providerDetails.getCode() < 400 && providerDetails.getOk()))
// {
// builder.up();

// } else {
Expand Down

0 comments on commit 7cc74ca

Please sign in to comment.