Share data or services between two independent modules within the same main project
Hello everyone,
I have a setup where I’m working with a main project (Project A) that contains all the Things with configurations for two sub-modules:
-
Project A – SubModule 1
-
Project A – SubModule 2
Each sub-module is component of Project A, and all configurations are stored in Project A’s Things.
We have already published Project A as an extension on the production server, so both sub-modules are currently working independently (i.e., there’s no direct dependency or linkage between SubModule 1 and SubModule 2).
Now, we have a new requirement where we need to access data from SubModule 1 inside SubModule 2.
However, due to the independent structure and the way Project A is packaged, I cannot simply make one module depend on the other.
💡 My current idea:
I’m considering creating a ThingTemplate inside the main Project A, and then creating corresponding Things for both SubModules 1 and 2 based on that template.
I could then write shared services inside this template and use the “Allow Override” option if I need to customize the logic separately for each sub-module.
This way, both modules would stay independent, but still have access to a shared service layer through the template defined in Project A.
Is this the best practice for achieving communication between two independent modules under one main project?
OR
Is there any alternative pattern that allows controlled data exchange or service usage between sub-modules while keeping them decoupled?
Any suggestions or best-practice guidance would be highly appreciated.
Thank you! 🙏

