hemerajs / hemera

🔬 Writing reliable & fault-tolerant microservices in Node.js https://hemerajs.github.io/hemera/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How robust ??

skalyanapu-mtuity opened this issue · comments

Hi @StarpTech

Here I would like to request you to provide some information about Hamera and its ecosystem.

  1. Hamera was using NATS as messaging system , i.e if I develop a group of Microservices , and if I use Hamera in each every service abstraction over them , they can communicate to each other based on pattern matching , i.e if my three micro services on three different servers like ( 192.23.45.6/7/8) and the NATS server is on another server , which maintains the communication b/w these services bases on its queues ??

So ,what if the centralised NATS server was down ?? Is there any fail safe ??

  1. I can provide a real time use why I'm concern about granuale distributed communications

Please assume have a use case of developing a standlone MS i.e API , which retrievs all the meta data required for an SPA , actaully there would be a group of SPA's in a container , each SPA has its own metadata , but the thought is to resue same retrieval MS i.e api by passing SPA name as query params to get exclusive data of respective metadata.

Now , main meta data retrivval service as : HOST/get-metadata?SPA=A/B/C/D (where A<B<C<D are names of diff SPA's)
Each of these sub metadata retrieval services or dockercontainers and or on different servers .

So, when HOST/get-metadata?SPA=A , was triggered main MS will to 'A' MS and get respective metadata related to that SPA only.But here "/get-metadata"don'nt the physical location where the MS related to A spa was hosted , just by pattern matching it should get the work done.

So all these complex communication was managed by NATS on centralised NATS server right ??

Please correct me if my assumptions at any pointare correct ??

Thanks for your time :)

Hi @skalyanapu-mtuity NATS is fire & forgot if your service is not available your request goes up into the air and you will get a Timeout error. To prevent such scenario you have to increase the instances (Node) of your service to be more fault tolerant. Additionally, you can cluster NATS on different machines https://nats.io/documentation/server/gnatsd-cluster/ and when a NATS cluster member goes down all traffic is redirected to the next.

Closed, due to inactivity.