内容简介:TODO首先,执行然后,编辑
指标系统
TODO
Prometheus
配置 Flink
首先,执行 cp opt/flink-metrics-prometheus-1.8.0.jar lib/
,将依赖的 JAR 文件拷贝到 /lib
目录下。
然后,编辑 conf/flink-conf.yaml 文件,添加配置:
metrics.reporter.prom.class: org.apache.flink.metrics.prometheus.PrometheusReporter
可选配置 metrics.reporter.prom.port
,Prometheus Exporter 监听端口,默认为 9249
。
可选配置 metrics.reporter.prom.filterLabelValueCharacters
,指定是否过滤不匹配 [a-zA-Z_][a-zA-Z0-9_]*
的 Label,默认为 false
。
重新启动 Flink 集群,Flink Prometheus 指标地址在 JobManager 所在主机的 9249 端口。
配置 Prometheus
编辑 prometheus.yml 配置文件,添加 Flink 集群指标配置:
scrape_configs:
- job_name: 'flink'
metrics_path: '/'
static_configs:
- targets: ['FLINK_MASTER:9249']
启动 Prometheus:
prometheus --config.file=prometheus.yml
Grafana
Grafana 是开源的仪表盘应用,官方支持 Prometheus 作为数据源。
添加 Prometheus 数据源,导入 Flink Metrics 。
以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持 码农网
本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们。
Agile Web Development with Rails 4
Sam Ruby、Dave Thomas、David Heinemeier Hansson / Pragmatic Bookshelf / 2013-10-11 / USD 43.95
Ruby on Rails helps you produce high-quality, beautiful-looking web applications quickly. You concentrate on creating the application, and Rails takes care of the details. Tens of thousands of deve......一起来看看 《Agile Web Development with Rails 4》 这本书的介绍吧!