Large Rule base failing? StackOverlowError
by Christie, Blair
We are having a problem reading in large serialized files. We get a
StackOverflow exception when the rules get to be 2m.
Is there a way to overcome this without increasing the stack size?
Blair Christie
15 years, 9 months
Problem using KnowledgeAgent
by Dan Seaver
I setup a KnowledgeAgent using the example code in the JavaDoc for
KnowledgeAgentFactory to access a compiled package in Guvnor. The package
runs fine, but changes to the package are not picked up. I believe this is
due to the ChangeSet notification thread being interrupted. But why?
Also, I'm getting some messages about failing to read schema document. I
think it is caused by the xml for the ChangeSet, but I'm using the example
from the JavaDocs.
Here's a snippet from the log:
[2009:02:48 23:02:905:info] KnowledegAgent has started listening for
ChangeSet notifications
[2009:02:48 23:02:905:info] KnowledgAgent created, with configuration:
monitorChangeSetEvents=true scanResources=true scanDirectories=true
[2009:02:48 23:02:905:exception
java.lang.RuntimeException: KnowledgeAgent ChangeSet notification thread has
been interrupted
at
org.drools.agent.impl.KnowledgeAgentImpl$ChangeSetNotificationDetector.run(KnowledgeAgentImpl.java:465)
at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.InterruptedException
at
java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.reportInterruptAfterWait(Unknown
Source)
at
java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(Unknown
Source)
at java.util.concurrent.LinkedBlockingQueue.take(Unknown Source)
at
org.drools.agent.impl.KnowledgeAgentImpl$ChangeSetNotificationDetector.run(KnowledgeAgentImpl.java:463)
... 1 more
[2009:02:48 23:02:937:info] KnowledegAgent has stopped listening for
ChangeSet notifications
(null: 1, 207): 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>.
(null: 1, 207): cvc-elt.1: Cannot find the declaration of element
'change-set'.
(null: 1, 216): 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>.
(null: 1, 343): 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>.
[2009:02:48 23:02:390:info] KnowledgAgent applying ChangeSet
--
View this message in context: http://www.nabble.com/Problem-using-KnowledgeAgent-tp22073944p22073944.html
Sent from the drools - user mailing list archive at Nabble.com.
15 years, 9 months
Re: [rules-users] Drools 5 in Eclipse 3.4.1 Newbie
by Mike Dean
What I did was start with Eclipse without any Drools 4.07 artifacts; restart
it clean, and then install Drools 5 plugins and features.
The problem I had was misunderstanding what they meant by run time Drools
setup. Go to the Drools preferences in Eclipse, select run time set up,
and you will see nothing. Tell it you want a default from the EClipse
plugin, and it will then give you a directory dialog. This is where I got
screwed up, but all it wants you to do is tell it where it should put the
runtime. It will then generate it automatically. Then everything works.
- Mike
adkirk wrote:
>
> I am having the exact same issue with Eclipse 3.4 and Drools 5.0. I
> originally installed Drools 4.0.7
> with Eclipse 3.4 and it worked OK, but I went to install 5.0 using the
> instructions in the docs - copying the jars into features and plugins and
> it doesn't do anything. I reinstalled Eclipse from scratch and Drools
> still doesn't show up anywhere in Eclipse.
>
> Is there something I'm missing.
>
> -Amanda
>
> Mike Dean wrote:
>>
>> Trying to move forward to Eclipse 3.4 so got it set up and now Drools
>> 5.0.0.M3 eclipse plugin and feature. Appears to have no effect, so am
>> guessing I have to load much more than that. The documentation
>> implies that I ought to be up and running. I was able to create a new
>> Drools project, but it would not function, asking for a run time
>> Drools setup. Removed these and tried to install 4.07 using the
>> Eclipse 3.3 update site, and that failed. Removed 4.07 artifacts as
>> far as I can tell, but now when I put the 5.0.0 feature and plugin
>> back, there is no sign of Drools. I am guessing that trying to load
>> the 4.07 from the update site has done something subtle to my Eclipse
>> setup, but no idea.
>>
>> Shorter question is whether there is more to installing Drools 5 in
>> Eclipse than is in the documentation. Thanks for any assistance.
>>
>> - Mike
>>
>>
>
>
--
View this message in context: http://www.nabble.com/Drools-5-in-Eclipse-3.4.1-Newbie-tp20653214p2211244...
Sent from the drools - user mailing list archive at Nabble.com.
15 years, 9 months
Using Servlet rule hosting instead of JBRMS
by Wilson O Ojwang
All,
Just want to know if its possible for one to write a servlet that can
host the packages (That is, instead of using JBRMS) that can be polled
by RuleAgent.newRuleAgent(Properties prop) with the following prop.
url=http://server:port/servletname/packages/
poll=300
localCacheDir=/home/username/resources/rules
Regards
Wilson
15 years, 9 months
Re: [rules-users] need help in running brms under tomcat
by David Sinclair
Issac,
You need to follow these instructions exactly.
http://www.jboss.org/community/docs/DOC-10130
Please confirm that you have.
On Thu, Feb 19, 2009 at 2:40 PM, Isaac Oren <isaacoren(a)yahoo.com> wrote:
>
> Thanks David, yes I looked at the logs and noticed I probebly miss some
> componnets, I don't remember seeing in the Drools doc anything about it, as
> I am new in this domain (old 'C' programmer).. what exactly do I need to
> get/installed ? from where ? and where to put it?? thank you so much..
> Isaac.
>
>
>
> --- On *Thu, 2/19/09, David Sinclair <dsinclair(a)chariotsolutions.com>*wrote:
>
> From: David Sinclair <dsinclair(a)chariotsolutions.com>
> Subject: Re: [rules-users] need help in running brms under tomcat
> To: "Isaac Oren" <isaacoren(a)yahoo.com>
> Date: Thursday, February 19, 2009, 11:35 AM
>
>
> This is the culprit
>
> Caused by: java.lang.NoClassDefFoundError:
> javax/faces/application/FacesMessage$Severity
>
> Looks like you may not have properly installed the JavaServerFaces jar
> files in tomcat. This class is contained in jsf-api.jar.
>
>
> On Thu, Feb 19, 2009 at 2:27 PM, Isaac Oren <isaacoren(a)yahoo.com> wrote:
>
>>
>> Thanks David, I actually saw that memo that's why I downloaded Tomcat
>> 5.5..
>>
>> I attach the logs that I think may be of interests, maybe they make some
>> sense.. I have tryied several time the process,,, thanks in advance.. Isaac,
>>
>>
>>
>> --- On *Thu, 2/19/09, David Sinclair <dsinclair(a)chariotsolutions.com>*wrote:
>>
>> From: David Sinclair <dsinclair(a)chariotsolutions.com>
>> Subject: Re: [rules-users] need help in running brms under tomcat
>> To: isaacoren(a)yahoo.com
>> Date: Thursday, February 19, 2009, 11:18 AM
>>
>>
>> Did u follow these instructions?
>>
>> http://www.jboss.org/community/docs/DOC-10130
>>
>> Also, there should be an associated log in your tomcat installation
>> dir/logs
>>
>> On Thu, Feb 19, 2009 at 2:14 PM, Isaac Oren <isaacoren(a)yahoo.com> wrote:
>>
>>>
>>> Thanks David,
>>>
>>> The war file (drools-jbrms) was downloaded from the Drools site today.. I
>>> think it was the onlu option for brms in the downloading page.How exactly
>>> can I get a trace when I use the Tomact Manager ? thanks, Isaac.
>>>
>>>
>>> --- On *Thu, 2/19/09, David Sinclair <dsinclair(a)chariotsolutions.com>*wrote:
>>>
>>> From: David Sinclair <dsinclair(a)chariotsolutions.com>
>>> Subject: Re: [rules-users] need help in running brms under tomcat
>>> To: isaacoren(a)yahoo.com, "Rules Users List" <rules-users(a)lists.jboss.org
>>> >
>>> Date: Thursday, February 19, 2009, 11:09 AM
>>>
>>>
>>> Which version of Drools? And is it really BRMS, or Guvnor u are trying to
>>> deploy? Also, there should be an associated stack trace for the failure.
>>> Please post that too.
>>>
>>> On Thu, Feb 19, 2009 at 2:02 PM, Isaac Oren <isaacoren(a)yahoo.com> wrote:
>>>
>>>>
>>>> I am trying to use Tomcat (5.5) on Windows to deploy the brms war file.
>>>>
>>>> I am using the Tomcat Manager simple (last) option to deploy the war
>>>> file, the response to the deploy actions is "OK". And indeed a proper
>>>> directory is created under the webapp directory.
>>>>
>>>> Nevertheless, the status on the Applications (running) is false and when
>>>> I try to start the application again I get the message:
>>>>
>>>>
>>>> FAIL - Application at context path /drools-jbrms could not be started
>>>>
>>>> any help will be appriciated, thanks, Isaac.
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>> _______________________________________________
>>>> rules-users mailing list
>>>> rules-users(a)lists.jboss.org
>>>> https://lists.jboss.org/mailman/listinfo/rules-users
>>>>
>>>>
>>>
>>
>
15 years, 9 months
need help in running brms under tomcat
by Isaac Oren
I am trying to use Tomcat (5.5) on Windows to deploy the brms war file.
I am using the Tomcat Manager simple (last) option to deploy the war file, the response to the deploy actions is "OK". And indeed a proper directory is created under the webapp directory.
Nevertheless, the status on the Applications (running) is false and when I try to start the application again I get the message:
FAIL - Application at context path /drools-jbrms could not be started
any help will be appriciated, thanks, Isaac.
15 years, 9 months
M2 repo for Drools 3.0.6
by GRILLON, Jean Pierre
Hi,
I'm looking for a public Maven2 repository for Drools v3.0.6.
Unfortunately, it seems to be missing into JBoss' repository:
http://repository.jboss.com/maven2/org/drools/
Could you please upload it?
Thanks,
Jean-Pierre
This message contains information that may be privileged or confidential and is the property of the Capgemini Group. It is
intended only for the person to whom it is addressed. If you are not the intended recipient, you are not authorized to
read, print, retain, copy, disseminate, distribute, or use this message or any part thereof. If you receive this message
in error, please notify the sender immediately and delete all copies of this message.
15 years, 9 months
Type Declaration exception from Guvnor
by Mike Dean
Trying to point at Guvnor with a URL, and the JBoss console indicates that
Guvnor is being properly hit. However, the following test case succeeds
only when I leave the try..catch clauses in both locations; if I remove the
try..catch clauses then the code does not finish (does not fail). However,
even when the unit test passes, I get the console message that follows the
test case. The model itself already has an import and declaration of the
class in question (top of source as reported by Guvnor is also shown). I am
confused by the fact that this test passes when I add the try .. catch
clauses (probably my Java naivete) but more perplexed because of the
exception. Have also uploaded the test case code and the DRL downloaded
from Guvnor in case it would be helpful. Assistance greatly appreciated.
- Mike
http://www.nabble.com/file/p22100280/KnowledgeFromGuvnorTest.java
KnowledgeFromGuvnorTest.java
http://www.nabble.com/file/p22100280/glucose.decision.rules.drl
glucose.decision.rules.drl
TEST CASE
package drools.engine;
import static org.junit.Assert.*;
import java.util.Collection;
import org.drools.KnowledgeBase;
import org.drools.KnowledgeBaseFactory;
import org.drools.builder.KnowledgeBuilder;
import org.drools.builder.KnowledgeBuilderFactory;
import org.drools.builder.ResourceType;
import org.drools.definition.KnowledgePackage;
import org.drools.io.ResourceFactory;
import org.junit.Test;
public class KnowledgeFromGuvnorTest {
private KnowledgeBase kbase = KnowledgeBaseFactory.newKnowledgeBase();
private KnowledgeBuilder kbuilder = KnowledgeBuilderFactory
.newKnowledgeBuilder();
@Test
public void testKnowledgeEngineFromURL(){
KnowledgeEngineFromGuvnor engine;
try {
engine = new
KnowledgeEngineFromGuvnor("http://localhost:8080/drools-guvnor/org.drools.guvnor.Guvnor/package/gluc...",
true);
}catch (Exception e) {
e.printStackTrace();
engine = null;
}
assertNotNull("Knowledge engine should not be null", engine);
assertFalse("There should not be builder errors", kbuilder.hasErrors());
}
public class KnowledgeEngineFromGuvnor {
public KnowledgeEngineFromGuvnor(String url, boolean guvnor) {
super();
System.out.println("Pushing URL into kbuilder");
try {
kbuilder.add(ResourceFactory.newUrlResource(url), ResourceType.PKG);
} catch (Exception e) {
System.out.println("Error occurred when URL was passed");
e.printStackTrace();
}
if (kbuilder.hasErrors()) {
System.out.println(kbuilder.getErrors().toString());
System.out.println("Unable to compile " + url + ".");
throw new RuntimeException("Bad things happened in
KnowledgeEngineFromGuvnor");
}
final Collection<KnowledgePackage> pkgs = kbuilder
.getKnowledgePackages();
kbase.addKnowledgePackages(pkgs);
}
}
}
SYSTEM CONSOLE OUTPUT
Pushing URL into kbuilder
Error occurred when URL was passed
org.drools.RuntimeDroolsException: unable to resolve Type Declaration class
'GlucoseDecisionState'
at org.drools.compiler.PackageBuilder.addPackage(PackageBuilder.java:766)
at
org.drools.compiler.PackageBuilder.addKnowledgeResource(PackageBuilder.java:521)
at
org.drools.builder.impl.KnowledgeBuilderImpl.add(KnowledgeBuilderImpl.java:30)
at
drools.engine.KnowledgeFromGuvnorTest$KnowledgeEngineFromGuvnor.<init>(KnowledgeFromGuvnorTest.java:43)
at
drools.engine.KnowledgeFromGuvnorTest.testKnowledgeEngineFromURL(KnowledgeFromGuvnorTest.java:27)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at
org.junit.internal.runners.TestMethodRunner.executeMethodBody(TestMethodRunner.java:99)
at
org.junit.internal.runners.TestMethodRunner.runUnprotected(TestMethodRunner.java:81)
at
org.junit.internal.runners.BeforeAndAfterRunner.runProtected(BeforeAndAfterRunner.java:34)
at
org.junit.internal.runners.TestMethodRunner.runMethod(TestMethodRunner.java:75)
at
org.junit.internal.runners.TestMethodRunner.run(TestMethodRunner.java:45)
at
org.junit.internal.runners.TestClassMethodsRunner.invokeTestMethod(TestClassMethodsRunner.java:66)
at
org.junit.internal.runners.TestClassMethodsRunner.run(TestClassMethodsRunner.java:35)
at
org.junit.internal.runners.TestClassRunner$1.runUnprotected(TestClassRunner.java:42)
at
org.junit.internal.runners.BeforeAndAfterRunner.runProtected(BeforeAndAfterRunner.java:34)
at org.junit.internal.runners.TestClassRunner.run(TestClassRunner.java:52)
at
org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:45)
at
org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196)
TOP OF SOURCE FROM GUVNOR
package glucose.decision.rules
import glucose.decision.object.GlucoseDecision;
import glucose.decision.object.GlucoseDecisionState;
declare GlucoseDecision
@propertyChangeSupport
end
declare GlucoseDecisionState
@propertyChangeSupport
end
(WHOLE BUNCH OF RULES FOLLOW)
JBOSS CONSOLE OUTPUT
06:08:33,104 INFO [STDOUT] PackageName: glucose.decision.rules
06:08:33,104 INFO [STDOUT] PackageVersion: LATEST
06:08:33,105 INFO [STDOUT] PackageIsLatest: true
06:08:33,105 INFO [STDOUT] PackageIsSource: false
--
View this message in context: http://www.nabble.com/Type-Declaration-exception-from-Guvnor-tp22100280p2...
Sent from the drools - user mailing list archive at Nabble.com.
15 years, 9 months