Hi Frank,
The rules are, on the whole, stored as XML (RuleModel passed through
XStream). See a previous exchange of emails on this forum about RuleModel,
it might prove useful.
However this is how we hand Rule persistence off to JCR; which in turn
stores it in another, lets say, internal format. Unfortunately I've not ran
JCR against a database to know what the resulting tables look like.
A colleague suggested use of DSL might help as you'd only need update the
DSL and recompile all rules. Might be worth a look?
Otherwise, using the REST API, or WEBDAV (not sure if it's more limited) to
retrieve a list of rules that can then be iterated and updated before
writing back might be the best option :(
With kind regards,
Mike
On 28 March 2011 15:37, FrankVhh <frank.vanhoenshoven(a)agserv.eu> wrote:
Hi,
Tx agaiin for the clarification on the .xml file. It makes a lot more
sense,
now.
Bulk update is indeed not provided, I was hoping to have a look at the way
the rules were stored (probably plain drl, or isn't it?) to assess what
effort a bulk update would take.
If you mean by your last statement to have rules that set the initial base
price, and afterwards add rules to modify the base price (when beverage(),
then b.augmentBasePrice(5)), I absolutely agree it is the best solution,
implementation-wise.
Regarding rule management and governance, there are a few issues that might
arise.
1) It is more difficult to get a view on your base prices
2) What if base prices are adapted manually to the desired level? Which
"adaptation rules" need to be deleted or changed?
I am not saying that this should be basic functionality of a brms, neither
am I very fond of the requirement myself. As it shifts the burden of work
from the business to the more technical people :-)
Regards,
Frank
manstis wrote:
>
> mortgage-sample-repository.xml is the example repository installed into
> Guvnor when you first deploy (and answer "yes" to the install
> examples
> prompt).
>
> Changing this XML will therefore have no effect, unless you re-import the
> XML too using the Administration functions in Guvnor.
>
> In order to achieve what you state you'd need to (a) use the JCR API to
> query the underlying datastore, (b) re-build your binary rule package. We
> don't provide a bulk update facility.
>
> Given your example would it be not best to have Beverages themselves as
> Facts and have rules that set their prices?
>
> Think of the Rules Engine as a RDBMS and the Facts as records.
>
> With kind regards,
>
> Mike
>
> On 28 March 2011 14:09, FrankVhh &lt;frank.vanhoenshoven(a)agserv.eu&gt;
> wrote:
>
> > Hi,
> >
> > Thanks for your quick reply, Salaboy.
> >
> > Webdav indeed allow me to browse through the packages and I was able
> to
> > locate a file mortgage-sample-repository.xml in the folder
> WEB-INF/classes
> > of drools-fuvnor.war.
> >
> > However, changes in the xml did not show up in Guvnor and vice
versa.
> So,
> > jackrabbit has to store its contents somewhere else. The folder
> > "repository"
> > only consists of class-files.
> >
> > The reason I am looking for this file, is because I am looking for
> ways to
> > simultaneously update multiple rule parameters, without adding a new
> rule
> > to
> > the ruleset. F.e. we want all base prices of our beverages to
> increase by
> > 5%.
> >
> > It would be as if you run an sql update statement on a "rule
> database".
> > You'll probably need to parse the drl to achieve this.
> >
> > Regards,
> > Frank
> >
> > --
> > View this message in context:
> >
>
http://drools-java-rules-engine.46999.n3.nabble.com/Rule-storage-tp274251...
> > Sent from the Drools - User mailing list archive at
Nabble.com.
> > _______________________________________________
> > rules-users mailing list
> > rules-users(a)lists.jboss.org
> >
https://lists.jboss.org/mailman/listinfo/rules-users
> >
>
> _______________________________________________
> rules-users mailing list
> rules-users(a)lists.jboss.org
>
https://lists.jboss.org/mailman/listinfo/rules-users
>
--
View this message in context:
http://drools-java-rules-engine.46999.n3.nabble.com/Rule-storage-tp274251...
Sent from the Drools - User mailing list archive at
Nabble.com.
_______________________________________________
rules-users mailing list
rules-users(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users