[rules-users] 5.3.0.Final throws RuntimeDroolsException: Unable to merge resource attribute for type declaration
Edson Tirelli
ed.tirelli at gmail.com
Fri Dec 9 20:33:42 EST 2011
Looks like a bug in the merging algorithm for types. Can any of you
please open a JIRA with a small test case and/or instructions on how to
reproduce plz?
Thank you,
Edson
On Fri, Dec 9, 2011 at 6:34 PM, jmgreen <john.green at hp.com> wrote:
> I was able to work around this problem by filtering out the
> KnowledgePackage
> containing my NormalizedEvent. In Drools 5.2.0 there was no problem
> adding
> this KnowledgePackage multiple times but apparently 5.3.0 doesn't cope with
> it well. I'm still not sure if that is a feature or a defect in 5.3.0.
> In any event doing the following make the exception go away.
>
> I'm still curious if this is a feature or a defect in 5.3.0. Any thoughts
> or opinions regarding are welcome.
>
>
> String globals = readDrlfile("globals.drl");
> String newRules = readDrlfile("rulesToAdd.drl");
> knowledgeBuilder.add(ResourceFactory.newReaderResource(new
> StringReader(globals + newRules)));
> if (knowledgeBuilder.hasErrors()) {
> throw exception ...
> }
> // No exception so compile succeeded --- BTW, it's using JANINO
> Collection<KnowledgePackage> pkgs =
> knowledgeBuilder.getKnowledgePackages();
>
>
> pkgs=filterOutAnyPackageThatHasNoRulesAndNameMatchingNormalizeEventPackageName(pkgs);
> knowledgeBase.addKnowledgePackages(pkgs); // NO ERROR ANYMORE
>
>
>
>
> --
> View this message in context:
> http://drools.46999.n3.nabble.com/rules-users-5-3-0-Final-throws-RuntimeDroolsException-Unable-to-merge-resource-attribute-for-type-den-tp3573815p3574420.html
> Sent from the Drools: User forum mailing list archive at Nabble.com.
> _______________________________________________
> rules-users mailing list
> rules-users at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/rules-users
>
--
Edson Tirelli
JBoss Drools Core Development
JBoss by Red Hat @ www.jboss.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/rules-users/attachments/20111209/e115768c/attachment.html
More information about the rules-users
mailing list