How to use the Chronicle-Network Library for service communication (APIs)?

484 Views Asked by At

I have two services that are deployed in the two different VMs. I want to call one service from other to get some data via APIs. That should need to have an ultra-low latency call.

For that how can I used the Chronicle-Network (https://github.com/OpenHFT/Chronicle-Network)?

Or Any other solution?

2

There are 2 best solutions below

3
On

I would suggest using Chronicle-Queue for passing messages from one service to another and back again. This is much lower latency than using TCP and easier to work with, provided the two VMs are on the same machine. You also get a record of every message making testing/debugging easier.

https://github.com/OpenHFT/Chronicle-Queue#high-level-interface-for-readingwriting

If you have two different machines I suggest either moving one VMs or using a low latency network card like Solarflare or Mellanox.

0
On

If you have a network call between VMs, try to use Chronicle Network. Another option is Aeron UDP unicast connection - https://github.com/real-logic/aeron