[rules-dev] Resource getName getDescription

Esteban Aliverti esteban.aliverti at gmail.com
Mon Sep 12 01:36:39 EDT 2011


Ok, I thought #droolsdev was ok too. Sorry about that.
The idea to have a 'name' and a 'description' attribute in <Resource>
elements inside a change-set is to tag them or to add them some
human-friendly information so you can refer to it not using the URL or the
name of the asset (could be duplicated in different packages), but with a
name and a description.
These changes are 100% end-users oriented, that is why I put those
attributes in API. End users applications (like Guvnor) could take
advantages on these new attributes.

So, a change-set now could look like this (the new attributes are not
mandatory):

<change-set>
    <add>
      <resource *name="Loan Rules" description="Rules about
loans"*type="DRL" source="
http://someHost:1234/someDRLResource.drl"/>
      <resource *name="Risk Rules" description="Rules about Risk evaluation"
* type="DRL" source="http://someHost:1234/someOtherDRLResource.drl"/>
    </add>
</change-set>

These attributes can also be used in Spring's configuration:

<drools:kbase id="kbase1" node="node1">
    <drools:resources>
        <resource *name="Loan Rules" description="Rules about
loans"*type="DRL" source="
http://someHost:1234/someDRLResource.drl"/>
        <resource *name="Risk Rules" description="Rules about Risk
evaluation"* type="DRL" source="
http://someHost:1234/someOtherDRLResource.drl"/>
    </drools:resources>
</drools:kbase>

WDYT?

Best Regards,

XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Esteban Aliverti
- Developer @ http://www.plugtree.com
- Blog @ http://ilesteban.wordpress.com


On Mon, Sep 12, 2011 at 6:25 AM, Mark Proctor <mproctor at codehaus.org> wrote:

> Shoudn't name and description be on InternalResource, not on Resource?
>
> I think it's time to put a restriction on changes to "-api". Feel free
> to change core/compiler etc, but if you want to change -api we'll need
> to propose it here.
>
> Mark
>
> _______________________________________________
> rules-dev mailing list
> rules-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/rules-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/rules-dev/attachments/20110912/84361047/attachment.html 


More information about the rules-dev mailing list