initial commit
Some checks failed
CI Pipeline / Build and Test (push) Successful in 4s
Security Scanning / Trivy — Filesystem & Dependency Scan (push) Failing after 7s
Security Scanning / Gitleaks — Secret Scan (push) Failing after 7s
Security Scanning / Security Summary (push) Failing after 3s
Build and Publish TechDocs / build-and-publish (push) Successful in 1m2s

Change-Id: I8e318861a258686ddc53dda08858f74c573a6520
This commit is contained in:
Scaffolder
2026-04-02 13:07:28 +00:00
commit 92edf90fd9
204 changed files with 104648 additions and 0 deletions

View File

@@ -0,0 +1,93 @@
# Copyright The OpenTelemetry Authors
# SPDX-License-Identifier: Apache-2.0
---
apiVersion: 1
groups:
- orgId: 1
name: otel-demo
folder: cart
interval: 1m
rules:
- uid: des78nlna99tsf
title: CartAddItemHighLatency
condition: p95_threshold
data:
- refId: p95_duration
relativeTimeRange:
from: 600
to: 0
datasourceUid: webstore-metrics
model:
editorMode: code
expr: |-
histogram_quantile(
0.95,
sum by (deployment_environment_name, service_namespace, service_name, service_instance_id, http_route, http_request_method, le) (
rate(
http_server_request_duration_seconds_bucket{
deployment_environment_name="",
service_namespace="opentelemetry-demo",
service_name="cart",
http_request_method="POST",
http_route="/oteldemo.CartService/AddItem"
}[5m]
)
)
)
instant: true
interval: ""
intervalMs: 1000
legendFormat: __auto
maxDataPoints: 43200
range: false
refId: p95_duration
- refId: p95_threshold
datasourceUid: __expr__
model:
conditions:
- evaluator:
params:
- 0.0001
type: gt
operator:
type: and
query:
params:
- C
reducer:
params: []
type: last
type: query
datasource:
type: __expr__
uid: __expr__
expression: p95_duration
intervalMs: 1000
maxDataPoints: 43200
refId: p95_threshold
type: threshold
dashboardUid: febljk0a32qyoa
panelId: 17
noDataState: NoData
execErrState: Error
for: 1m
keepFiringFor: 2m
annotations:
description: |-
The 95th percentile response time for operation {{ $labels.service_namespace
}}/{{ $labels.service_name }} "{{ $labels.http_request_method }} {{
$labels.http_route }}" has been
above xxx seconds for 2 minutes on {{ $labels.service_instance_id}}. Current
value: {{ .Value | humanizeDuration }}.
summary: |-
High P95 for {{ $labels.service_namespace }}/{{ $labels.service_name }} "{{
$labels.http_request_method }} {{ $labels.http_route }}"
labels:
service_name: cart
service_namespace: opentelemetry-demo
severity: warning
team_name: webstore
isPaused: false
notification_settings:
receiver: grafana-default-email

View File

@@ -0,0 +1,341 @@
{
"annotations": {
"list": [
{
"builtIn": 1,
"datasource": {
"type": "grafana",
"uid": "-- Grafana --"
},
"enable": true,
"hide": true,
"iconColor": "rgba(0, 211, 255, 1)",
"name": "Annotations & Alerts",
"type": "dashboard"
}
]
},
"editable": true,
"fiscalYearStartMonth": 0,
"graphTooltip": 0,
"id": 6,
"links": [],
"panels": [
{
"datasource": {
"type": "prometheus",
"uid": "webstore-metrics"
},
"description": "The total number of accepted client connections",
"fieldConfig": {
"defaults": {
"color": {
"mode": "thresholds"
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "green"
},
{
"color": "red",
"value": 80
}
]
}
},
"overrides": []
},
"gridPos": {
"h": 8,
"w": 5,
"x": 0,
"y": 0
},
"id": 1,
"options": {
"colorMode": "value",
"graphMode": "area",
"justifyMode": "auto",
"orientation": "auto",
"percentChangeColorMode": "standard",
"reduceOptions": {
"calcs": [
"lastNotNull"
],
"fields": "",
"values": false
},
"showPercentChange": false,
"textMode": "auto",
"wideLayout": true
},
"pluginVersion": "12.0.2",
"targets": [
{
"datasource": {
"type": "prometheus",
"uid": "webstore-metrics"
},
"disableTextWrap": false,
"editorMode": "builder",
"expr": "nginx_connections_accepted_total",
"fullMetaSearch": false,
"includeNullMetadata": true,
"legendFormat": "__auto",
"range": true,
"refId": "A",
"useBackend": false
}
],
"title": "Accepted connections",
"type": "stat"
},
{
"datasource": {
"type": "prometheus",
"uid": "webstore-metrics"
},
"description": "The total number of handled connections",
"fieldConfig": {
"defaults": {
"color": {
"mode": "thresholds"
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "green"
},
{
"color": "red",
"value": 80
}
]
}
},
"overrides": []
},
"gridPos": {
"h": 8,
"w": 5,
"x": 5,
"y": 0
},
"id": 3,
"options": {
"colorMode": "value",
"graphMode": "area",
"justifyMode": "auto",
"orientation": "auto",
"percentChangeColorMode": "standard",
"reduceOptions": {
"calcs": [
"lastNotNull"
],
"fields": "",
"values": false
},
"showPercentChange": false,
"textMode": "auto",
"wideLayout": true
},
"pluginVersion": "12.0.2",
"targets": [
{
"disableTextWrap": false,
"editorMode": "builder",
"expr": "nginx_connections_handled_total",
"fullMetaSearch": false,
"includeNullMetadata": true,
"legendFormat": "{{__name__}}",
"range": true,
"refId": "A",
"useBackend": false
}
],
"title": "Connections handled",
"type": "stat"
},
{
"datasource": {
"type": "prometheus",
"uid": "webstore-metrics"
},
"description": "The total number of client requests",
"fieldConfig": {
"defaults": {
"color": {
"mode": "thresholds"
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "green"
}
]
}
},
"overrides": []
},
"gridPos": {
"h": 8,
"w": 9,
"x": 10,
"y": 0
},
"id": 4,
"options": {
"colorMode": "value",
"graphMode": "area",
"justifyMode": "auto",
"orientation": "auto",
"percentChangeColorMode": "standard",
"reduceOptions": {
"calcs": [
"lastNotNull"
],
"fields": "",
"values": false
},
"showPercentChange": false,
"textMode": "auto",
"wideLayout": true
},
"pluginVersion": "12.0.2",
"targets": [
{
"disableTextWrap": false,
"editorMode": "builder",
"expr": "nginx_requests_total",
"fullMetaSearch": false,
"includeNullMetadata": true,
"legendFormat": "{{__name__}}",
"range": true,
"refId": "A",
"useBackend": false
}
],
"title": "Total number of client requests",
"type": "stat"
},
{
"datasource": {
"type": "prometheus",
"uid": "webstore-metrics"
},
"description": "The current number of nginx connections by state",
"fieldConfig": {
"defaults": {
"color": {
"mode": "palette-classic"
},
"custom": {
"axisBorderShow": false,
"axisCenteredZero": false,
"axisColorMode": "text",
"axisLabel": "",
"axisPlacement": "auto",
"barAlignment": 0,
"barWidthFactor": 0.6,
"drawStyle": "line",
"fillOpacity": 0,
"gradientMode": "none",
"hideFrom": {
"legend": false,
"tooltip": false,
"viz": false
},
"insertNulls": false,
"lineInterpolation": "linear",
"lineWidth": 1,
"pointSize": 5,
"scaleDistribution": {
"type": "linear"
},
"showPoints": "auto",
"spanNulls": false,
"stacking": {
"group": "A",
"mode": "none"
},
"thresholdsStyle": {
"mode": "off"
}
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "green"
},
{
"color": "red",
"value": 80
}
]
}
},
"overrides": []
},
"gridPos": {
"h": 11,
"w": 19,
"x": 0,
"y": 8
},
"id": 2,
"options": {
"legend": {
"calcs": [],
"displayMode": "list",
"placement": "bottom",
"showLegend": true
},
"tooltip": {
"hideZeros": false,
"mode": "single",
"sort": "none"
}
},
"pluginVersion": "12.0.2",
"targets": [
{
"disableTextWrap": false,
"editorMode": "builder",
"expr": "nginx_connections_current",
"fullMetaSearch": false,
"includeNullMetadata": true,
"legendFormat": "{{state}}",
"range": true,
"refId": "A",
"useBackend": false
}
],
"title": "Number of connections by state",
"type": "timeseries"
}
],
"preload": false,
"schemaVersion": 41,
"tags": [],
"templating": {
"list": []
},
"time": {
"from": "now-15m",
"to": "now"
},
"timepicker": {},
"timezone": "browser",
"title": "[Image-Provider] NGINX Metrics",
"uid": "6fb665e0-cb81-40a5-bd21-a9485c5477b4",
"version": 1
}

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,459 @@
{
"annotations": {
"list": [
{
"builtIn": 1,
"datasource": {
"type": "grafana",
"uid": "-- Grafana --"
},
"enable": true,
"hide": true,
"iconColor": "rgba(0, 211, 255, 1)",
"name": "Annotations & Alerts",
"type": "dashboard"
}
]
},
"editable": true,
"fiscalYearStartMonth": 0,
"graphTooltip": 0,
"id": 3,
"links": [],
"panels": [
{
"fieldConfig": {
"defaults": {},
"overrides": []
},
"gridPos": {
"h": 2,
"w": 24,
"x": 0,
"y": 0
},
"id": 8,
"options": {
"code": {
"language": "plaintext",
"showLineNumbers": false,
"showMiniMap": false
},
"content": "This dashboard shows the use of metric exemplars.\nExemplars can be used to look up a trace in Jaeger.\nOnly the most recent exemplars may still be available in Jaeger.\n<br>\nChart panels may require 5 minutes after the Demo is started before rendering data.",
"mode": "html"
},
"pluginVersion": "11.6.1",
"title": "",
"type": "text"
},
{
"collapsed": false,
"gridPos": {
"h": 1,
"w": 24,
"x": 0,
"y": 2
},
"id": 4,
"panels": [],
"title": "GetCart Exemplars",
"type": "row"
},
{
"datasource": {
"type": "prometheus",
"uid": "webstore-metrics"
},
"fieldConfig": {
"defaults": {
"custom": {
"hideFrom": {
"legend": false,
"tooltip": false,
"viz": false
},
"scaleDistribution": {
"type": "linear"
}
}
},
"overrides": []
},
"gridPos": {
"h": 9,
"w": 24,
"x": 0,
"y": 3
},
"id": 2,
"interval": "2m",
"options": {
"calculate": false,
"cellGap": 1,
"color": {
"exponent": 0.5,
"fill": "dark-orange",
"mode": "scheme",
"reverse": false,
"scale": "exponential",
"scheme": "Spectral",
"steps": 64
},
"exemplars": {
"color": "rgba(255,0,255,0.7)"
},
"filterValues": {
"le": 1e-09
},
"legend": {
"show": true
},
"rowsFrame": {
"layout": "auto"
},
"tooltip": {
"mode": "single",
"showColorScale": false,
"yHistogram": false
},
"yAxis": {
"axisPlacement": "left",
"reverse": false
}
},
"pluginVersion": "11.6.1",
"targets": [
{
"disableTextWrap": false,
"editorMode": "builder",
"exemplar": true,
"expr": "sum by(le) (rate(app_cart_get_cart_latency_seconds_bucket[$__rate_interval]))",
"format": "heatmap",
"fullMetaSearch": false,
"includeNullMetadata": false,
"instant": true,
"legendFormat": "{{le}}",
"range": true,
"refId": "A",
"useBackend": false
}
],
"title": "GetCart Latency Heatmap with Exemplars",
"type": "heatmap"
},
{
"datasource": {
"type": "prometheus",
"uid": "webstore-metrics"
},
"fieldConfig": {
"defaults": {
"color": {
"mode": "palette-classic"
},
"custom": {
"axisBorderShow": false,
"axisCenteredZero": false,
"axisColorMode": "text",
"axisLabel": "",
"axisPlacement": "auto",
"barAlignment": 0,
"barWidthFactor": 0.6,
"drawStyle": "line",
"fillOpacity": 0,
"gradientMode": "none",
"hideFrom": {
"legend": false,
"tooltip": false,
"viz": false
},
"insertNulls": false,
"lineInterpolation": "linear",
"lineWidth": 1,
"pointSize": 5,
"scaleDistribution": {
"type": "linear"
},
"showPoints": "auto",
"spanNulls": false,
"stacking": {
"group": "A",
"mode": "none"
},
"thresholdsStyle": {
"mode": "off"
}
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "green"
},
{
"color": "red",
"value": 80
}
]
}
},
"overrides": []
},
"gridPos": {
"h": 10,
"w": 24,
"x": 0,
"y": 12
},
"id": 5,
"interval": "2m",
"options": {
"legend": {
"calcs": [],
"displayMode": "list",
"placement": "bottom",
"showLegend": true
},
"tooltip": {
"hideZeros": false,
"mode": "single",
"sort": "none"
}
},
"pluginVersion": "11.6.1",
"targets": [
{
"datasource": {
"type": "prometheus",
"uid": "webstore-metrics"
},
"disableTextWrap": false,
"editorMode": "builder",
"exemplar": true,
"expr": "histogram_quantile(0.95, sum by(le) (rate(app_cart_get_cart_latency_seconds_bucket[$__rate_interval])))",
"fullMetaSearch": false,
"includeNullMetadata": false,
"legendFormat": "p95 GetCart",
"range": true,
"refId": "A",
"useBackend": false
}
],
"title": "95th Pct Cart GetCart Latency with Exemplars",
"type": "timeseries"
},
{
"collapsed": false,
"gridPos": {
"h": 1,
"w": 24,
"x": 0,
"y": 22
},
"id": 3,
"panels": [],
"title": "AddItem Exemplars",
"type": "row"
},
{
"datasource": {
"type": "prometheus",
"uid": "webstore-metrics"
},
"fieldConfig": {
"defaults": {
"custom": {
"hideFrom": {
"legend": false,
"tooltip": false,
"viz": false
},
"scaleDistribution": {
"type": "linear"
}
}
},
"overrides": []
},
"gridPos": {
"h": 9,
"w": 24,
"x": 0,
"y": 23
},
"id": 6,
"interval": "2m",
"options": {
"calculate": false,
"cellGap": 1,
"color": {
"exponent": 0.5,
"fill": "dark-orange",
"mode": "scheme",
"reverse": false,
"scale": "exponential",
"scheme": "Spectral",
"steps": 64
},
"exemplars": {
"color": "rgba(255,0,255,0.7)"
},
"filterValues": {
"le": 1e-09
},
"legend": {
"show": true
},
"rowsFrame": {
"layout": "auto"
},
"tooltip": {
"mode": "single",
"showColorScale": false,
"yHistogram": false
},
"yAxis": {
"axisPlacement": "left",
"reverse": false
}
},
"pluginVersion": "11.6.1",
"targets": [
{
"disableTextWrap": false,
"editorMode": "builder",
"exemplar": true,
"expr": "sum by(le) (rate(app_cart_add_item_latency_seconds_bucket[$__rate_interval]))",
"format": "heatmap",
"fullMetaSearch": false,
"includeNullMetadata": false,
"instant": true,
"legendFormat": "{{le}}",
"range": true,
"refId": "A",
"useBackend": false
}
],
"title": "AddItem Latency Heatmap with Exemplars",
"type": "heatmap"
},
{
"datasource": {
"type": "prometheus",
"uid": "webstore-metrics"
},
"fieldConfig": {
"defaults": {
"color": {
"mode": "palette-classic"
},
"custom": {
"axisBorderShow": false,
"axisCenteredZero": false,
"axisColorMode": "text",
"axisLabel": "",
"axisPlacement": "auto",
"barAlignment": 0,
"barWidthFactor": 0.6,
"drawStyle": "line",
"fillOpacity": 0,
"gradientMode": "none",
"hideFrom": {
"legend": false,
"tooltip": false,
"viz": false
},
"insertNulls": false,
"lineInterpolation": "linear",
"lineWidth": 1,
"pointSize": 5,
"scaleDistribution": {
"type": "linear"
},
"showPoints": "auto",
"spanNulls": false,
"stacking": {
"group": "A",
"mode": "none"
},
"thresholdsStyle": {
"mode": "off"
}
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "green"
},
{
"color": "red",
"value": 80
}
]
}
},
"overrides": []
},
"gridPos": {
"h": 10,
"w": 24,
"x": 0,
"y": 32
},
"id": 1,
"interval": "2m",
"options": {
"legend": {
"calcs": [],
"displayMode": "list",
"placement": "bottom",
"showLegend": true
},
"tooltip": {
"hideZeros": false,
"mode": "single",
"sort": "none"
}
},
"pluginVersion": "11.6.1",
"targets": [
{
"datasource": {
"type": "prometheus",
"uid": "webstore-metrics"
},
"disableTextWrap": false,
"editorMode": "builder",
"exemplar": true,
"expr": "histogram_quantile(0.95, sum by(le) (rate(app_cart_add_item_latency_seconds_bucket[$__rate_interval])))",
"fullMetaSearch": false,
"includeNullMetadata": false,
"legendFormat": "p95 AddItem",
"range": true,
"refId": "A",
"useBackend": false
}
],
"title": "95th Pct Cart AddItem Latency with Exemplars",
"type": "timeseries"
}
],
"preload": false,
"schemaVersion": 41,
"tags": [],
"templating": {
"list": []
},
"time": {
"from": "now-15m",
"to": "now"
},
"timepicker": {},
"timezone": "browser",
"title": "Cart Service Exemplars",
"uid": "ce6sd46kfkglca",
"version": 1
}

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,23 @@
# Copyright The OpenTelemetry Authors
# SPDX-License-Identifier: Apache-2.0
apiVersion: 1
datasources:
- name: Prometheus
uid: webstore-metrics
type: prometheus
url: http://prometheus:9090
editable: true
isDefault: true
jsonData:
# Align Prometheus data source time interval with the OTel SDKs' export interval (see OTEL_METRIC_EXPORT_INTERVAL)
timeInterval: "60s"
exemplarTraceIdDestinations:
- datasourceUid: webstore-traces
name: trace_id
- url: http://localhost:8080/jaeger/ui/trace/$${__value.raw}
name: trace_id
urlDisplayLabel: View in Jaeger UI

View File

@@ -0,0 +1,22 @@
# Copyright The OpenTelemetry Authors
# SPDX-License-Identifier: Apache-2.0
apiVersion: 1
datasources:
- name: Jaeger
uid: webstore-traces
type: jaeger
url: http://jaeger:16686/jaeger/ui
editable: true
isDefault: false
jsonData:
tracesToLogsV2:
datasourceUid: webstore-logs
spanStartTimeShift: "-20m"
spanEndTimeShift: "20m"
filterByTraceID: true
filterBySpanID: true
customQuery: true
query: traceId:"$${__trace.traceId}" AND spanId:"$${__span.spanId}"

View File

@@ -0,0 +1,21 @@
# Copyright The OpenTelemetry Authors
# SPDX-License-Identifier: Apache-2.0
apiVersion: 1
datasources:
- name: OpenSearch
uid: webstore-logs
type: grafana-opensearch-datasource
url: http://opensearch:9200/
access: proxy
editable: true
isDefault: false
jsonData:
database: otel-logs-*
flavor: opensearch
logLevelField: severity.text.keyword
logMessageField: body
pplEnabled: true
timeField: observedTimestamp
version: 3.4.0