In this series of articles, we will focus on the SAP Cloud ALM Raw Data API.
The SAP Cloud ALM raw data API implements the OpenTelemetry protocol to provide access to the observability signals produced by SAP Cloud ALM.
In the previous post we introduced the SAP Cloud ALM Raw Data Metrics API.
In this blog, we will illustrate how to use this API to export and import metrics managed by the SAP Cloud ALM health monitoring use case.
From the Landscape Management SAP Cloud ALM application
Find the system information to identify the system ID as shown below:
From the Health Monitoring SAP Cloud ALM application
Select the system containing the metrics you want to export:
You will find the list of metrics reported for your system:
From an HTTP client, access to the following URL:
GET https://{{HOST}}/api/calm-metrics/v1/metrics?version=V1&provider=hm&dimensions=serviceType,serviceName,serviceId,metricName,metricLabel&prefix=demo-hm&resolution=5Mi&prefix=demo-qm7&metrics=measure:value&shift=1&serviceId=3c8c7cd1-a346-4af1-a52e-428e53848669&format=protobuf-json
Parameters | Value |
provider | hm for health monitoring |
serviceId | Set the source serviceId of your system |
format | protobuf-json |
dimensions, metrics | The list of dimensions/metrics to be exported |
prefix | optional prefix for the metric name |
Check the SAP Business Accelerator HUB for a complete list of parameters.
The output payload contains the list of metrics in protobuf-json.
{
"name": "demo-qm7_ABAP.Workprocess.Stopped",
"gauge": {
"dataPoints": [
{
"timeUnixNano": "1690307700000000000",
"asDouble": 0.0,
"attributes": [
{
"key": "Instance",
"value": {
"stringValue": "LDCIQM7_QM7_20"
}
},
{
"key": "Wp_status",
"value": {
"stringValue": "Stopped"
}
},
{
"key": "Wp_type",
"value": {
"stringValue": "BTC"
}
},
{
"key": "Sid",
"value": {
"stringValue": "QM7"
}
},
{
"key": "measure",
"value": {
"stringValue": "value"
}
}
]
},
From an HTTP client, access to the following URL:
POST https://{{HOST}}/api/calm-metrics/v1/metrics?useCase=hm&serviceId=e5fd8c2e-4326-4813-befa-23b22c148010&format=protobuf-json
Query
Parameters | Value |
serviceId | Set the serviceId of the target system |
format | protobuf-json |
useCase | hm to inject the metrics in the Health Monitoring use-case |
Check the SAP Business Accelerator HUB for a complete list of parameters.
Body
Attach a compatible OTeL payload for metrics content in the body of this message.
From the Health Monitoring SAP Cloud ALM application
Check the result in the “All Metrics” tab
In the next article, we will look into the SAP Cloud ALM raw data logs API.
Thanks for reading.