1 Star 2 Fork 0

sarba_home/vertx-examples

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
README.adoc 1.12 KB
一键复制 编辑 原始数据 按行查看 历史
zhanghongtao 提交于 2023-12-20 13:23 . vertx 4.x 官网实例提交

Vert.x Kafka Client examples

Here you will find examples demonstrating the usage of the Vert.x Kafka Client.

Monitoring dashboard

The monitoring dashboard examples shows the usage of both the producer and consumer APIs of the Kafka client.

The MetricsVerticle.java uses the Kafka producer API to produce metrics in Json format.

The DashboardVerticle.java uses the Kafka consumer API to consume the metrics and send them to a monitoring dashboard using the Event Bus.

The MainVerticle.java is the main program you should start as it starts a Kafka broker and then configures the DashboardVerticle and the MetricsVerticle with their consumer and producer config.

Run the MainVerticle main method and then open your browser at http://localhost:8080/

In real usage the Kafka broker would probably be managed externally and the DashboardVerticle / MetricsVerticle executed separately with their own configuration.

马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Java
1
https://gitee.com/sarba/vertx-examples.git
git@gitee.com:sarba/vertx-examples.git
sarba
vertx-examples
vertx-examples
master

搜索帮助

23e8dbc6 1850385 7e0993f3 1850385