我使用Spring Boot 2以以下格式将指标导出到InfluxDB:
metricsController.getCountriesByCoverageKm().forEach(response ->
List<Tag> tags = Arrays.asList(Tag.of("country.iso2", response.getIso2()), Tag.of("country.name", response.getName()));
meterRegistry.gauge("countries.by.coverage.km",tags, response.getCoverageKm());
});
我的目标是在Grafana中创建一个表格,该表格代表所有国家及其编号。原始方式是针对每个国家/地区写查询,这些查询将在表格中显示为单独的行:
在Grafana中,有没有更聪明的方法来制作表格以减少查询数量?如何遍历所有报告的标签以获取值?