More document for meter configurations in backend-meter.md (#7637)
This commit is contained in:
parent
2220a72c5f
commit
7d428ecc2d
|
|
@ -64,6 +64,7 @@ Release Notes.
|
|||
* Add a section in `Log Collecting And Analysis` doc, introducing the new Python agent log reporter.
|
||||
* Add one missing step in `otel-receiver` doc about how to activate the default receiver.
|
||||
* Reorganize dynamic configuration doc.
|
||||
* Add more description about meter configurations in `backend-meter` doc.
|
||||
|
||||
All issues and pull requests are [here](https://github.com/apache/skywalking/milestone/96?closed=1)
|
||||
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@
|
|||
The meter receiver accepts the metrics of [meter protocol](https://github.com/apache/skywalking-data-collect-protocol/blob/master/language-agent/Meter.proto) into the [meter system](./../../concepts-and-designs/meter.md).
|
||||
|
||||
## Module definition
|
||||
Module definition is defined in `application.yml`, typically located at `$SKYWALKING_BASE_DIR/config/application.yml` by default.
|
||||
```yaml
|
||||
receiver-meter:
|
||||
selector: ${SW_RECEIVER_METER:default}
|
||||
|
|
@ -17,6 +18,13 @@ kafka-fetcher:
|
|||
bootstrapServers: ${SW_KAFKA_FETCHER_SERVERS:localhost:9092}
|
||||
```
|
||||
|
||||
## Meter collection
|
||||
|
||||
Metrics named in OAL script could be used in MAL, as described in [Official OAL script](../../guides/backend-oal-scripts.md)
|
||||
|
||||
Custom metrics may be collected by Manual Meter API. You may find correct APIs diving into [Server Agents](../service-agent/server-agents.md).
|
||||
Custom metrics collected cannot be used directly, they should be configured in `meter-analyzer-config` configuration files, which is described in next part.
|
||||
|
||||
## Configuration file
|
||||
The meter receiver is configured via a configuration file. The configuration file defines everything related to receiving
|
||||
from agents, as well as which rule files to load.
|
||||
|
|
@ -24,7 +32,16 @@ The meter receiver is configured via a configuration file. The configuration fil
|
|||
The OAP can load the configuration at bootstrap. If the new configuration is not well-formed, the OAP may fail to start up. The files
|
||||
are located at `$CLASSPATH/meter-analyzer-config`.
|
||||
|
||||
The file is written in YAML format, defined by the scheme described below. Brackets indicate that a parameter is optional.
|
||||
New meter-analyzer-config files is **NOT** enabled by default, you should make meter configuration take effect through section `agent-analyzer` in `application.yml` of skywalking backend.
|
||||
```yaml
|
||||
agent-analyzer:
|
||||
selector: ${SW_AGENT_ANALYZER:default}
|
||||
default:
|
||||
# ... take care of other analyzers
|
||||
meterAnalyzerActiveFiles: ${SW_METER_ANALYZER_ACTIVE_FILES:your-custom-meter-conf-without-ext-name} # The multiple files should be separated by ","
|
||||
```
|
||||
|
||||
Meter-analyzer-config file is written in YAML format, defined by the scheme described below. Brackets indicate that a parameter is optional.
|
||||
|
||||
An example can be found [here](../../../../oap-server/server-bootstrap/src/main/resources/meter-analyzer-config/spring-sleuth.yaml).
|
||||
If you're using Spring Sleuth, see [Spring Sleuth Setup](spring-sleuth-setup.md).
|
||||
|
|
@ -42,9 +59,10 @@ expSuffix: <string>
|
|||
metricPrefix: <string>
|
||||
# Metrics rule allow you to recompute queries.
|
||||
metricsRules:
|
||||
# The name of rule, which combinates with a prefix 'meter_' as the index/table name in storage.
|
||||
# The name of rule, which combinates with a prefix '<metricPrefix>_' as the index/table name in storage.
|
||||
# The name with prefix can also be quoted in UI (Dashboard/Template/Item/Metrics)
|
||||
name: <string>
|
||||
# MAL expression.
|
||||
# MAL expression. Raw name of custom metrics collected can be used here
|
||||
exp: <string>
|
||||
```
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue