Data exchange between verticals in Vert.x

What's the best way to exchange data in Vert.x between vertices? I'm most interested in low, direct, parallel access. The event system doesn't seem to fit if multiple vertices need to be able to access things that are large enough that their economy isn't sent as json.

A simple example - consider a mock email service using Vert.x. Let's say that it has two verticals, one to determine the next package to send, and the other to figure out the fuel spent in the previous hour on vehicles delivering the packages.

Say there are 1000 packages at any given time. There might be a database returning them, but then it will need to return all packets as the algorithms for determining which packet to send / spent fuel are complex enough and run by two verticals.

So far I have found them:

Some suggestions:

  • Use JSON.stringify

    / JSON.parse

    via vertx.getMap

    . This looks pretty overhead to me, especially when things are updated frequently (for example, the package location may contain a GPS coordinate)
  • Use EHCache, Hazelcast, etc., but they mostly die with "you can try" without details.

Is there a canonical Vert.x solution that I have not been able to recognize? I'm fine with dividing things up differently, having more vertices, lower / higher granularity, etc., if so, then there is a more architectural question regarding the Vert.x model.

I'm also interested in seeing the open source examples linked to above, if any.

+3


source to share


1 answer


The history of clustering for applications node

is slim, especially if you don't want to use Java.



Since it seems that you want to have control of the communication level at the lowest level, I would recommend connecting event buses between vertices using regular web maps.

0


source







All Articles