Pablo, I've been working with this for a long time already using C # in an interdependent system! I think even though we are interdent, we have managed to modu- late the system in general.
We have our own methodology for building our specializations by modules, not exactly as shown in the Microsoft on the subject.
Our system started all modular, but over time it went (naturally) to being fully integrated. We have many customers who still buy only a few modules. But there comes an intrinsic need: Integrations !
Example: Buying modules where you are an expert
Here's a case: You're a specialist in stock control and logistics. Your system is amazing in these modules, but it sucks to make incredible HML5 presentations with millions of photos updated every week.
If a customer comes to you for expertise in this matter, you'll probably need several integrations: Inbound invoices to know what's going into inventory (purchases and stock returns), an up-to-date materials orders and stock reservations and another for invoices to exit the inventory. Maybe even another integration for notification of broken materials.
Modular Sales
Nowadays we are already more mature with regard to sales of modules in separate. Although we have modules and specializations (for example, we sell the billing module, but in Brazil we invoice one way, in Chile in another, etc.), we also have a solid integration mechanism for all the modules.
Of course, there is an interdependence between all the modules. Even if the customer wants to buy only one module or another, it is necessary to map the interdependencies and make sure that they get a solid product.
Specialized Modular Mechanism
The way we do today is as follows: Our modules are loaded one by one by common interfaces distributed in the system. There is a Factory
of these interfaces that verifies, every time it is called, whether the module has already been loaded or not, if it is not it loads (each of our modules is in a module-specific and specialization DLL for easy visualization) .
We use a lot of reflection for these cases. It's worth a look. We have a common DLL that defines what is an object of type Modulo
and common interfaces that this object must implement. Then these objects can be instantiated and used when needed.
You can call the billing module at any point in the system to bill an order, for example ModuloFaturamento.FaturarPedido(codigoPedido);
. If the customer owns the module, the order is actually invoiced. Otherwise, a stub can be implemented to do nothing or an integration can be done with a request for an external system (eg SAP).
Summary
I believe that modularisation is quite feasible, but there is considerable expense in integrations when the client does not want all the modules. Try to specialize in the modules in which your current customers give more importance. Understand all of it and become reference. Others will begin to come more naturally if necessary.