mrproliu edited a comment on issue #6118:
URL: https://github.com/apache/skywalking/issues/6118#issuecomment-753561680
I thought about the format of the configuration file. The configuration can
also be placed in the same directory and can be distinguished by files based on
different metrics.
```yaml
entities: # All entities support the metrics
- service: test_service # Combine all hosts, adding prefix "zabbix:"
instance-pattern: .+ # All hosts will support keys, adding prefix
"zabbix:"
metrics:
- name: system_cpu_util # Save to meter system name, adding prefix "meter_"
keys: # Define need receive data keys from agent, all key update limit
is `1m`, support number value only
- system.cpu.util[,system]
- system.cpu.util[,user]
- system.cpu.util[,iowait]
- system.cpu.util[,idle]
exp: system.cpu.util # MAL expression
```
When the agent asks which metrics keys need to be monitored, it will obtain
all `metrics.keys` according to `entities.instance-pattern`. Also:
1. keys that are repeatedly declared will be deduplicated before sending.
2. If `entities.instance-pattern` is declared in multiple configuration
files, then `metrics.keys` among them will tell the agent to query.
When pushing data content on the agent side, the data will also be
aggregated into the `entities.service` service according to the specified
`host`. The data content is generated based on all `metrics.exp` and
`metrics.keys`.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]