Clustering and Shared Data in Vert.x

前端 未结 5 423
无人共我
无人共我 2021-02-01 07:09

I\'m developing in Vert.x (based on Netty and Hazelcast), and I\'m trying to share data between two server instances (eache of those instances in different machines, on the same

5条回答
  •  时光取名叫无心
    2021-02-01 07:43

    As has been pointed out, the data sharing objects bundled in Vert.x don't support sharing data across multiple Vert.x instances. In order to do that you would have to do either:

    1. Use a "normal" shared database.
    2. Set up a Verticle which manages the SharedMap instances and publishes and listens for updates to and from the rest of the cluster.
    3. Design your application so you don't need to share data in this way.

提交回复
热议问题