Eclipse Agenda View not working in 5.0.0.M4
by Herman Post
Hi,
I am trying to debug a rule using Eclipse 3.4, Drools 5.0.0.M4, and all I ever see in the Agenda View is:
MAIN[nofocus]=BinaryHeapQueueAgendaGroup (id=2259)
I can step into the rule successfully and WorkingMemory View works too.
Any suggestions?
Thanks,
Herman Post
15 years, 11 months
Retrieving facts from a database
by Bryan Basham
Hi all,
I've been lurking on this alias for a while but I have not seen any questions about this so I thought I would ask...
Our application is DB intensive with potentially millions of rows in certain tables. Currently, we are testing Drools in our app with small data sets that can easily be loaded into Java heap memory, but we are concerned about the scalability of our design. My question is: Does Drools support a mechanism to dynamically load pages of facts into the working memory? Or do you have to load *all* facts in at one time as we are currently doing it?
Any pointers (especially to web pages or documentation) would be appreciated.
Thanks,
Bryan
15 years, 11 months
Serialized Files to big 4.07
by Christie, Blair
We have a large rule based which leads to a large serialized file.
As a result we are starting to see issues reading in the rule base into
our client application.
Is there a way to reduce the size of the rule base to reduce the memory
footprint.
Cheers,
Blair
15 years, 11 months
Delete Repository Files ok for DB backed repository?
by Barry K
I have a DB repository backing my JBRMS but have a question about the
jackrabbit files that are created on the file system.
1) Is this scaffolding information regenerated from the data if the database
is migrated to a new server or do these files need to be promoted to the new
server as well?
The answer to the first may answer this one for me but....
2) When running in a clustered environment with a DB backed repository each
server will generate it's own repository files. Is there a synchronization
issue to worry about with these files.
Thanks
Barry
--
View this message in context: http://www.nabble.com/Delete-Repository-Files-ok-for-DB-backed-repository...
Sent from the drools - user mailing list archive at Nabble.com.
15 years, 11 months
Problem using BRMS and Knowledge Agent
by psentosa
Hi all,
I'm having problem getting the KnowledgeAgent and Guvnor working
correctly...
On the console I got this reports:
12:35:05,265 INFO [STDOUT] [2009:01:13 12:01:265:info]
ResourceChangeScanner created with default interval=60
12:35:05,265 INFO [STDOUT] [2009:01:13 12:01:265:info]
ResourceChangeScanner reconfigured with interval=30
12:35:06,468 INFO [STDOUT] [2009:01:13 12:01:468:info]
ResourceChangeNotification created
12:35:06,468 INFO [STDOUT] [2009:01:13 12:01:468:debug]
ResourceChangeNotification monitor added
monitor=org.drools.io.impl.ResourceChangeScannerImpl@241eaf
12:35:06,468 INFO [STDOUT] [2009:01:13 12:01:468:debug] KnowledgeAgent
building resource map
12:35:06,468 INFO [STDOUT] [2009:01:13 12:01:468:info] KnowledegAgent has
started listening for ChangeSet notifications
12:35:06,468 INFO [STDOUT] [2009:01:13 12:01:468:info] KnowledgAgent
created, with configuration:
monitorChangeSetEvents=true scanResources=true scanDirectories=true
12:35:06,500 INFO [STDOUT] (null: 3, 88): schema_reference.4: Failed to
read schema document 'drools-change-set-5.0.xsd', because 1) could not find
the document; 2) the document could not be read; 3) the root element of the
document is not <xsd:schema>.
12:35:06,500 INFO [STDOUT] (null: 3, 88): cvc-elt.1: Cannot find the
declaration of element 'change-set'.
12:35:06,500 INFO [STDOUT] (null: 4, 7): schema_reference.4: Failed to read
schema document 'drools-change-set-5.0.xsd', because 1) could not find the
document; 2) the document could not be read; 3) the root element of the
document is not <xsd:schema>.
12:35:06,500 INFO [STDOUT] (null: 7, 17): schema_reference.4: Failed to
read schema document 'drools-change-set-5.0.xsd', because 1) could not find
the document; 2) the document could not be read; 3) the root element of the
document is not <xsd:schema>.
12:35:06,500 INFO [STDOUT] [2009:01:13 12:01:500:info] KnowledgAgent
applying ChangeSet
12:35:06,500 INFO [STDOUT] [2009:01:13 12:01:500:debug] KnowledgeAgent
subscribing to resource=[UrlResource
path='http://localhost:8080/drools-guvnor/org.drools.guvnor.Guvnor/package/regu...']
12:35:06,500 INFO [STDOUT] [2009:01:13 12:01:500:debug]
ResourceChangeNotification subscribing
listener=org.drools.agent.impl.KnowledgeAgentImpl@1ca7c02 to
resource=[UrlResource
path='http://localhost:8080/drools-guvnor/org.drools.guvnor.Guvnor/package/regu...']
12:35:06,500 INFO [STDOUT] [2009:01:13 12:01:500:debug]
ResourceChangeScanner subcribing
notifier=org.drools.io.impl.ResourceChangeNotifierImpl@939c8a to
resource=[UrlResource
path='http://localhost:8080/drools-guvnor/org.drools.guvnor.Guvnor/package/regu...']
12:35:06,500 INFO [STDOUT] [2009:01:13 12:01:500:debug] KnowledgeAgent
ChangeSet requires KnowledgeBuilder
12:35:06,500 INFO [STDOUT] [2009:01:13 12:01:500:debug] KnowledgeAgent
rebuilding KnowledgeBase using ChangeSet
12:35:06,500 INFO [STDOUT] PackageName: regulation
12:35:06,500 INFO [STDOUT] PackageVersion: regulation
12:35:06,500 INFO [STDOUT] PackageIsLatest: false
12:35:06,500 INFO [STDOUT] PackageIsSource: false
12:35:06,515 INFO [STDOUT] PackageName: regulation
12:35:06,515 INFO [STDOUT] PackageVersion: regulation
12:35:06,515 INFO [STDOUT] PackageIsLatest: false
12:35:06,515 INFO [STDOUT] PackageIsSource: false
12:35:06,718 INFO [STDOUT] [2009:01:13 12:01:718:debug] KnowledgeAgent
adding KnowledgeDefinitionsPackage regulation
12:35:06,843 INFO [STDOUT] [2009:01:13 12:01:843:debug] KnowledgeAgent
building resource map
...
as you can see, there is this line saying that it failed to read the
schema-document. I don't know whether this could cause the problem I have
right now: although a rule in the package regulation should fire (it is as
easy as to check if "number < 5" then print out something), and I have
indeed input a number smaller than 5, but it didn't.
It also has those PackageIsLatest/PackageIsSource are "false" (how to get
them set to true? at least for PackageIslatest)
my code looks like this:
public List<String> getViolatedRegulation(final List<Activity> activities )
{
LOG.info("Checking rules ... ");
final List<String> violatedRegulation = new ArrayList<String>();
this.ksession = this.getSession();
this.ksession.setGlobal("violatedRegulation", violatedRegulation);
this.ksession.executeObject(new Object[] {activities});
return violatedRegulation;
}
(An activity object has an attribute "number": a rule checks whether the
number < 5)
private StatelessKnowledgeSession getSession() {
LOG.info("Getting session for Rules Engine ...");
// Set the interval on the ResourceChangeScannerService if you are to use
it
// and default of 60s is not desirable.
final ResourceChangeScannerConfiguration sconf =
ResourceFactory.getResourceChangeScannerService()
.newResourceChangeScannerConfiguration();
// set the disk scanning interval to 30s, default is 60s
sconf.setProperty("drools.resource.scanner.interval", "30");
ResourceFactory.getResourceChangeScannerService().configure(sconf);
this.kbase = KnowledgeBaseFactory.newKnowledgeBase();
final KnowledgeAgentConfiguration aconf =
KnowledgeAgentFactory.newKnowledgeAgentConfiguration();
// we want to scan directories, not just files, turning this on turns on
file
// scanning
aconf.setProperty("drools.agent.scanDirectories", "true");
// resource changes results in a new instance of the KnowledgeBase being
// built, this cannot currently be set to false for incremental building
aconf.setProperty("drools.agent.newInstance", "true");
final KnowledgeAgent kagent =
KnowledgeAgentFactory.newKnowledgeAgent("kagent", this.kbase,
aconf);
kagent.applyChangeSet(ResourceFactory.newFileResource("c:/changeset.xml"));
return kagent.getKnowledgeBase().newStatelessKnowledgeSession();
}
changeset.xml looks as follows:
<change-set xmlns='http://drools.org/drools-5.0/change-set'
xmlns:xs='http://www.w3.org/2001/XMLSchema-instance'
xs:schemaLocation='http://drools.org/drools-5.0/change-set
drools-change-set-5.0.xsd'>
<add>
<resource
source='http://localhost:8080/drools-guvnor/org.drools.guvnor.Guvnor/package/regu...'
type='PKG' />
</add>
</change-set>
Thanks for any explanation
Regards
Paul
--
View this message in context: http://www.nabble.com/Problem-using-BRMS-and-Knowledge-Agent-tp21434310p2...
Sent from the drools - user mailing list archive at Nabble.com.
15 years, 11 months
Problem with (examples for )Guvnor M3 (mortgage, advertisement)
by psentosa
Dear all,
I'm testing Guvnor for the first time (M3, never tried the previous
versions) and try to run the mortgage example first.
In the example folder, there's a .txt file which describes how to run it.
So I imported the repository and wanted to take a look at the rules. When I
clicked on the name of the category (from AssetView) or any asset (from
Package view), it displayed "Please wait..loading data", which unfortunately
didn't progress further. So I have to cancel it by clicking on the x to get
back to the previous screen.
On the console there's the report
"Checking access for...*name of the category*" (for clicking on a category)
and
"INFO [STDOUT] DEBUG 08-12 18:03:33,390
(ServiceImplementation.java:listAssets:883) time for asset list load: 0"
(for clicking on an asset type from the Package view).
So I thought maybe I should defined the access right in the Administration
page (this is also described in the .txt file); So I create a user
permission with admin right, shut down the server, set the property "enable
role-based-authorization" to true, repack, re-run the server and try again.
Still I experience the same problem.
For the other example Advertising I also experienced the same problem.
Several questions I have:
- Should I always define the acces right to be able to browse through the
categories/asset? But apparently I still have problems although user
permissions are defined. Or maybe I progress in a wrong way to use the
Guvnor?
- In the example mortgage, I saw that the client has drools-core-5.0.0.MR2
and mvel-2.0M2. Could it be the problem, that the example was created using
GuvnorM2 so it didn't work for M3?
Unfortunately the documentation of M3 is for some part already out-of-date.
Would be nice to have the most actual one :)
Many thanks for any reply!
regards
--
View this message in context: http://www.nabble.com/Problem-with-%28examples-for-%29Guvnor-M3-%28mortga...
Sent from the drools - user mailing list archive at Nabble.com.
15 years, 11 months
How to add rules to working memory during livetime?
by Trägenap
Hi,
I want to add a new rule to an existing workingmemory. I not want to
loose the "situation" in this workingmemory.
First I create a new workingmemory and insert a couple of facts.
After firingAllRules it could be possible to add some new rules (load
some new drl-files) to the existing workingmemory without loosing the
facts inside this.
Is this possible?
First idea was to retrieve all facts from the workingmemory, create a
new one including the new rules and insert all facts again?
Is this the correct way?
Thanks
Thorsten
15 years, 11 months
Memory Leak in BRMS for ruleAgent?
by richarda
We are seeing a memory leak when running Drools 4.0.7 JBRMS
We have the JBRMS deployed and some package snapshots taken.
Seperately a client is running rulesAgent
ruleAgent= RuleAgent.newRuleAgent(agentProps);
with properties looking like:
url=http://...
poll=60
localCacheDir=...
It seems that polling the JBRMS is leaving some memory leak each time...
eventually the application service runs out of memory. (it takes days.. but
running jconsole you can see the memory usage growing)
This has been reproduced on JBOSS appserver, and glassfish.
Has anyone else experienced this?
Any suggestions?
Thanks
Ric
--
View this message in context: http://www.nabble.com/Memory-Leak-in-BRMS-for-ruleAgent--tp21376597p21376...
Sent from the drools - user mailing list archive at Nabble.com.
15 years, 11 months
how can drools file access class from an external jar
by Jason Novotny
Hi,
I'm using maven to organize my project into modules. I have all my
drools related code in one module called xxx-rules and things work fine.
However, if I move one of the classes referenced by a .drl rules file
into another module xxx-core it doesn't work anymore. Does anyone know
how I can instruct the loader to look for the class in a different maven
module?
Thanks, Jason
15 years, 11 months