With all this rumbling about microservices, I started to look alternatives ways to decouple modules, because of the network communication difficulties.
In my search for more lightweight and easier methods, I can across several ideas communication solutions:
- Cross-Context in web containers, interesting solution but not all containers support it
- Good old Sockets and UNIX Domain Sockets, truly lightweight but comes with a cost of complexity
- Big ball of mud with modules and importing spring contexts
- SOA, microservices or just services ... watherver, http communication
- Middleware messaging communication such as JMS or AMQP
- Files, slow and not even remotely easy to manage
- Communication through database
- Pipes and named pipes, actually a neat solution but does not scale
- OSGi looks like something I am looking for
The question is, did I miss something? I need a scalable solution, that keeps modules decoupled and allows for easy adoption. Preferably without network overhead. Is there a way to use the same interface in Java between modules, and invoke hidden implementation behind and endpoint, locally, without exposing it as a tight dependency?
And please do not tell me that a good project architecture can keep things separated, without a mandatory separation with time and growth projects will become tightly coupled and fragile.
Also, maybe I am missing the picture, maybe there are other places decoupling can take place?