this is fixed in trunk, but it won't make it into the 3.0.x series.

Mark
Holla wrote:
unfortunately one of the facts (which is provided others) has an attribute
"duration", and rules are not getting compiled...

rule "Duration Check"
when
    ThirdPartyFact( duration > 40 )
then
    ...
end


Drools (3.0.4) documentation says:
"There are some reserved keywords that are used in the rule language. It is wise
to avoid collisions with these words when naming your domain objects,
properties, methods, functions and so on that are used in the rule text. The
following list are words that you should try and avoid in the rule contents if
possible (often times it will work fine, but in some cases the rules may be
parsed incorrectly)"

especially the last sentence is very confusing.. it does not rule out
possibility attribute names like "duration". even eclipse plugin does not report
an error!! but compiling with package builder failed saying "Unexpected token
'duration'" :(

i feel Drools should always allow attributes with name same as that of a
keyword. duration is a very common name... or at least the documentation &
plugin should strictly disallow such usage.


_______________________________________________
rules-users mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/rules-users


_______________________________________________
rules-users mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/rules-users

Reply via email to