Best practice for common rule override
hi,
My team wanted to build a common library/application i.e. Global_CaseManagement where the application will be exported to 2 instances for 2 regions to share (similar to a common library), i.e. UK_Bank and US_Bank.
Let's name the rule as rule!Global_GetNextCase which used within a node by a common global process model namely ACTION - Get Next Case
Given the rule Global_GetNextCase will have different logic for UK and US, what would be the recommended way to do the common rule override?
The dependency graph as below :
1. Global (application) -> ACTION - Get Next Case -> rule!Global_GetNextCase -> rule!Global_GetNextCase_UK
2. Global (application) -> ACTION - Get Next Case -> rule!Global_GetNextCase -> rule!Global_GetNextCase_US
This way will create a problem where both UK and US rules will be imported into the instances respectively causing unwanted dependency issue, cause UK only needs Global_GetNextCase_UK while US only needs Global_GetNextCase_US
Another method by using local!result: getrulereferencebyname("rule!Global_GetNextCase_" & cons!region) where this way will resolve the unwanted dependency issue, but it will be dynamically calling the expression rule, we are thinking this might not be the best practice since the dependency cannot be traced.
Any suggestion on the best practice?
