scaling nodejs based micro services

Siddique Ahmad
2 min readFeb 7, 2022

Someone on linkedin asked for nodejs based micro services, I replied him my view but writing here so others can review and share their experiences too.

Socket is a communication link, and if used among services, it will require high availability for those, which is hard to maintain.

I will suggest outbox pattern. We can go with incremental approach suggested below.

Outbox pattern is approach where we save dual writes and not directly call micro service or publish message.

  1. Standalone debezium server and REST change consumer. Standalone debezium server will cut down the learning curve for kafka and it’s stack.
scaling-microservices

2. Change rest change consumer to NATS server. You can use rabbitmq, or apache artemis too.

3. Use debezium stack, with schema registry and kafka with avro. Schema registry and avro will save you on data size. Specially the schema registry will not only save disk size but also will make it easy for others to consume it.

4. Even though I wish it should be on number 1, but it depends on prior experience with apache flink, it is something which is extra ordinary way to handle micro services at scale, it is apache flink stateful functions. And amazing thing is there is no database required for this, just a simple s3 compatible storage device.

Last one needs many posts to explain its benefits. you can see on the link attached.

--

--

Siddique Ahmad

Passionate about devops, data analytics, business solutions, #kubernets @debezium flink-statefun, kogito