[
http://jira.jboss.com/jira/browse/JBRULES-613?page=all ]
Edson Tirelli closed JBRULES-613.
---------------------------------
Fix Version/s: 4.0.0.MR2
(was: 4.0.0.MR3)
Resolution: Done
Can't use dollar ($) char in Rule Name with Janino compiler
-----------------------------------------------------------
Key: JBRULES-613
URL:
http://jira.jboss.com/jira/browse/JBRULES-613
Project: JBoss Rules
Issue Type: Bug
Security Level: Public(Everyone can see)
Components: Drl Parser/Builder
Affects Versions: 3.0.5
Environment: Verified on WinXP and OS X
Reporter: Bree VanOss
Assigned To: Edson Tirelli
Priority: Minor
Fix For: 4.0.0.MR2
Essentially it appears that any rule using the U.S. Dollar character ($) in the
rule name fails when compiled with Janino. I was able to reproduce the issue
using the "default" new JBoss-rules project wizard in Eclipse.
The stack trace follows, though it may not be much help. I tried tracking it
down and it looks like the problem is actually caused in the parse/compilation
step (i.e. builder.addPackageFromDrl( source );). After this step the rule in
question has a null "consequence", which causes the
"AbstractRuleBase.addRule(...)" method to fail when it does the isValid()
check.
<code>
java.lang.IllegalArgumentException: The rule called Show me da $ is not valid.
Check for compile errors reported.
at org.drools.common.AbstractRuleBase.addRule(Unknown Source)
at org.drools.reteoo.ReteooRuleBase.addRule(Unknown Source)
at org.drools.common.AbstractRuleBase.addPackage(Unknown Source)
at com.sample.DroolsTest.readRule(DroolsTest.java:89)
at com.sample.DroolsTest.main(DroolsTest.java:29)
</code>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira