5 ms·
There is another downside, much more problematic in my experience - the failure modes of a distributed system (even over multiple processes in the same machine)
by beagle3 4y ago
There is another downside, much more problematic in my experience - the failure modes of a distributed system (even over multiple processes in the same machine) are very different. The other process might be killed by OOM manager, user initiated kill signal, or a bug. All of a sudden, asking an object for its string identifier xyz.Name() becomes a possibly failing operation even though it succeeded a microsecond ago.
- mcculley 4y agoYes, there are downsides to distributed systems. In some cases, they are still necessary. This approach allows us to make the decision to be distributed at runtime instead of at design time. For our services, there is never a single point of failure. We use Resilience4j for retries, caching inside the dynamic proxy handler (using annotations to describe what is cacheable), and annotations to describe what can be done asynchronously. In the cases where we use these, the caller is aware (via the interface documentation) that this is a distributed system where sometimes invocations happen really fast and reliably.
- beagle3 4y agoI was referring to your "only downside" statement (size and mutability of messages). No, that's far from the only downside, and in my experience, not even the most important one. > In the cases where we use these, the caller is aware (via the interface documentation) that this is a distributed system where sometimes invocations happen really fast and reliably. This is at odds with > I have systems where the decision to put the module in the same process or to call it via RPC is done at runtime. Either it's in the caller's choice (based on the documentation), or it's at runtime, but it can't be both and be equally reliable.
- mcculley 4y agoI meant "only downside" in terms of how to design the API parameters and return values. I did not say it is the caller's choice nor that it is equally reliable. It is a system composition decision. It is a system that is sometimes distributed and treated as such from a reliability point of view. Sometimes the actual implementation is more reliable and faster.