Vertx结合Dropwizard Metrics对服务的各项指标提供度量监控,因参考文章编写详细,本文对实践Metrics 监控可视化记录html
https://vertx.io/docs/vertx-dropwizard-metrics/java/java
https://my.oschina.net/chkui/blog/707632git
https://blog.csdn.net/ifrozen/article/details/53161413 (参考文章)json
vertx-dropwizard-metrics 3.8.2app
jolokia-jvm-1.6.2-agent https://jolokia.org/download.htmleclipse
hawtio-app-2.7.1.jar https://github.com/hawtio/hawtio/releasesjvm
实践参考文章,不一样点在于版本,另外是经过eclipse配置VM arguments启动,在hawtio不能看到vertx JMX监控项ui
配置VM arguments以下:spa
-Dvertx.metrics.options.jmxDomain=vertx -Dvertx.metrics.options.enabled=true -Dvertx.metrics.options.jmxEnabled=true
修改成代码配置,可正常显示,配置以下:
vertx = Vertx.vertx(new VertxOptions().setMetricsOptions( new DropwizardMetricsOptions() .setEnabled(true) .setJmxEnabled(true) .setJmxDomain("vertx-metrics")));