I had the same strange problem some time ago (last winter), but I never managed to reproduce a small sample....
I checked, and my problematic class hierarchy also lived in different packages (and never tried that that for my smaller samples).


De: "Joerg Henne" <hennejg+nabble@googlemail.com>
À: rules-users@lists.jboss.org
Envoyé: Lundi 30 Juillet 2012 16:04:50
Objet: Re: [rules-users] Apply role to whole class hierarchy

After some debugging I was able to shed some light on what causes the
problem, even if I don't fully understand it. The problem is produced by the
event base class, which is declared with @role(event), i.e. (VSCPEvent)
living in a different package than the ButtonEvent. If I move then into the
same package, everything works just fine.
The two package instances are merged in PackageBuilder.mergePackage(...),
but the RuleBuilder still seems to operate on two separate instances, one
with the declarations and Package.isEvent(...) returning true for the
ButtonEvent and the other without them. Unfortunately, as I know too little
about the workings of the various builders, I can't provide you with a
ready-made idea of how to fix the problem.

See https://issues.jboss.org/browse/JBRULES-3587

Thanks
Joerg



--
View this message in context: http://drools.46999.n3.nabble.com/Apply-role-to-whole-class-hierarchy-tp4018930p4018963.html
Sent from the Drools: User forum mailing list archive at Nabble.com.
_______________________________________________
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users