Help Desk Ticket Reference: https://c.na7.visual.force.com/apex/Case_View?id=500A0000007BHi5&sfdc.override=1 securitylevel_name: Public Drools should not allow set two rules with the same name for the same package As expected, Drools does not allow us to define two rules with the same name in a same DRL file. But if there are two rules with the same name, in the same package, but in separate files, no exception or warning is issued, just one rule overrides the other in silence. From documentation: "A rule must have a name, unique within its rule package. If a rule is defined twice in a single DRL, an error will appear when one loads it. If a DRL that includes a rule name already in the package is added, the previous rule is repalced."[1] [1] http://docs.redhat.com/docs/en-US/JBoss_Enterprise_SOA_Platform/5/html/JBoss_Rules_5_Reference_Guide/chap-language_reference.html#sect-rule Different behavior for a similar action is not good. Both should alert user about a rule name repeated. For large projects using a lot of DRL files can be hard to track mistakes occurred by rules override . It is really necessary provide an ERROR message for this.
Link: Added: This issue Cloned to BRMS-597
Customer is watching BZs, but issue is not a show-stopper. GSS calls this 'medium'.
https://issues.jboss.org/browse/JBRULES-3063 was already fixed by Edson Tirelli, so changing assignee and changing status to MODIFIED.
Please verify the issue on 5.3 ER4.
Verified in 5.3 ER4.
Technical note added. If any revisions are required, please edit the "Technical Notes" field accordingly. All revisions will be proofread by the Engineering Content Services team. New Contents: JBoss BRMS does not allow multiple rules with the same name in a package. When a second rule with the same name as another rule is added to a package it replaces the original rule, however, JBoss BRMS did not warn the user this was occurring. This has been resolved by adding warnings with 'INFO', 'WARN', and 'ERROR'. When configured with the ERROR severity for rule and function replacement, package compilation will fail.
The [1] which is above comments referred, but page can not found which click it. I also can not found in BRMS 5.3.1 docs as [2] [1] http://docs.redhat.com/docs/en-US/JBoss_Enterprise_SOA_Platform/5/html/JBoss_Rules_5_Reference_Guide/chap-language_reference.html#sect-rule [2] https://access.redhat.com/site/documentation/en-US/JBoss_Enterprise_BRMS_Platform/5/html/JBoss_Rules_5_Reference_Guide/index.html
As [1] hints the issue is fixed in drools 5.3.0.Final, but I test via BRMS 5.3.0 the issue still existed [1] https://issues.jboss.org/browse/JBRULES-3063
Can you please clarify how you tested? By default, BRMS does allow rule replacement... it will only raise errors when the engine is configured to raise errors for rule duplication.
This product has been discontinued or is no longer tracked in Red Hat Bugzilla.