[jboss-jira] [JBoss JIRA] (JBRULES-2438) Loading multiple sheets of single Excel book by one change-set xml should fail gracefully if multiple sheets use the same RuleTable name
RH Bugzilla Integration (JIRA)
jira-events at lists.jboss.org
Thu Aug 30 08:23:34 EDT 2012
[ https://issues.jboss.org/browse/JBRULES-2438?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12714841#comment-12714841 ]
RH Bugzilla Integration commented on JBRULES-2438:
--------------------------------------------------
Geoffrey De Smet <gdesmet at redhat.com> made a comment on [bug 724313|https://bugzilla.redhat.com/show_bug.cgi?id=724313]
It's possible to do it, here's a unit test on 5.3.x (also on 5.4.x and master):
https://github.com/droolsjbpm/drools/commit/57df74328e2d7e4b41e80bc43beb6d3264f1374e
But if multiple sheets use the same RuleTable name it should fail gracefully.
I 'll take a look at that failing gracefully to fix this issue.
> Loading multiple sheets of single Excel book by one change-set xml should fail gracefully if multiple sheets use the same RuleTable name
> ----------------------------------------------------------------------------------------------------------------------------------------
>
> Key: JBRULES-2438
> URL: https://issues.jboss.org/browse/JBRULES-2438
> Project: Drools
> Issue Type: Feature Request
> Security Level: Public(Everyone can see)
> Components: drools-core
> Affects Versions: 5.0.1.FINAL
> Reporter: Toshiya Kobayashi
> Assignee: Geoffrey De Smet
>
> I'm trying to use rules via DecisionTable using change-set.
> I wrote rules in multiple sheets of single Excel book.
> Then I configured my change-set xml like:
> ...
> <add>
> <resource source='classpath:data/dtable.xls' type="DTABLE">
> <decisiontable-conf input-type="XLS" worksheet-name="sheet1" />
> </resource>
> <resource source='classpath:data/dtable.xls' type="DTABLE">
> <decisiontable-conf input-type="XLS" worksheet-name="sheet2" />
> </resource>
> </add>
> ...
> But only rules of sheet1 were loaded.
> As far as I observed source codes, KnowledgeAgentImpl.java puts resource into "Map<Resource, ResourceMapping> resources". But even if multiple resources are configured in change-set, it appears to me like those resources are considered as the same resource and eventually only one resource will be registered.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list