Hacker News new | ask | show | jobs
by kuchenbecker 935 days ago
Build modules not micro services and deploy your module as a microservice, sidecar, cli, lambda, library dependency, etc as appropriate for the situation. Those interfaces are best as a thin shim on top of the core functionality.

Microservice is a particular interface. If you have GRPC or REST errors being thrown from a function, you're probably letting the interface leak into your program. .

1 comments

Microservice works in a purposeful implementation. Otherwise it is safer to build a modular monolith to eliminate REST latency. A process talking to a process is nanoseconds or less, REST is in the high nanoseconds to miliseconds. The volume of processes depends on latency. You can only process so much based on how fast a task's cycle time takes to complete.
I agree! In Polylith, the built artifact(s) is an implementation detail and you can decide what to build (a set of Microservices or a monolith) when you are ready for it.